Hellow
I am using a sheduler to update a table after every 30 min. but
only updating the first row from the table and not going through every row individually and performing the queries?
Anybody tell me where and how i set a loop.....
here is my code:
PHP Code:
function query ( $bibid , $copyid ) {
$sql = $this -> mkSQL ( "select biblio_copy.*, "
. " biblio_hold.holdid, biblio_hold.hold_begin_dt, biblio_hold.hold_exp_dt "
. "from biblio_copy, biblio_hold "
. "where biblio_copy.bibid = biblio_hold.bibid "
. " and biblio_copy.copyid= biblio_hold.copyid "
. " and biblio_copy.status_begin_dt = biblio_hold.hold_begin_dt "
. " and to_days(biblio_hold.hold_exp_dt) < to_days(sysdate()) " ,
$bibid , $copyid );
}
function update ( $copy ) {
$sql = $this -> mkSQL ( "update biblio_copy set "
. "status_cd=%Q, "
. "status_begin_dt=sysdate(), " ,
$copy -> getStatusCd ());
}
Plz Help
Regards