<?php


function cs_get_iou_batches_with_no_tran_date(){
    $sql = "SELECT batch_no FROM  ".TB_PREF."i_owe_you_batches 
            WHERE tran_date < '1970-01-01'";
    return db_query($sql,"Could not cs_get_iou_batches_with_no_tran_date");
}


function cs_update_iou_batch_tran_date()
{
    $result = cs_get_iou_batches_with_no_tran_date();
    while ($row = db_fetch($result)) {
        if(isset($row['batch_no']) && $row['batch_no'] > 0){
            update_iou_batch_tran_date($row['batch_no']); 
        }
    }
}

?>