Changeset 4841 for temp


Ignore:
Timestamp:
2006/09/17 13:07:16 (20 years ago)
Author:
kakinaka
Message:

blank

File:
1 edited

Legend:

Unmodified
Added
Removed
  • temp/trunk/html/admin/batch/daily.php

    r4840 r4841  
    235235    $start_age = null; 
    236236    $end_age = null; 
    237      
    238237    // ǯÎðËè¤Ë½¸·×¤¹¤ë¡£ 
    239238    for($i = 0; $i <= $age_loop; $i++) { 
     
    265264    $base_where = "WHERE (create_date BETWEEN ? AND ?) AND customer_id = 0 AND del_flg = 0"; 
    266265    $where = $base_where . " AND (to_number(to_char(age(current_timestamp, order_birth), 'YYY'), 999) BETWEEN ? AND ?) "; 
    267      
     266 
     267     
     268    $end_date = date("Y/m/d", time());  
     269    $start_date = date("Y/m/d",strtotime("-10 year")); 
     270    $start_age = null; 
     271    $end_age = null; 
    268272    // ǯÎðËè¤Ë½¸·×¤¹¤ë¡£ 
     273    for($i = 0; $i <= $age_loop; $i++) { 
     274        $where = $base_where . " AND order_birth >= cast('$start_date' as date)"; 
     275        if($i <= $age_loop) { 
     276            $where = $where . " AND order_birth <= cast('$end_date' as date)"; 
     277        } 
     278        lfBatOrderAgeSub($sql . $where, $start, $end, $start_age, $end_age, 1); 
     279        $end_date = date("Y/m/d",strtotime("1 day" ,strtotime($start_date))); 
     280        $start_date = date("Y/m/d",strtotime("-10 year",strtotime($end_date))); 
     281    } 
     282 
    269283/* 
    270284    for($i = 0; $i <= $age_loop; $i++) { 
Note: See TracChangeset for help on using the changeset viewer.