"; $result = mysql_query("select * from rep_his_data_everyday where RHD_DATE>(select DATE_SUB(sysdate(), INTERVAL 90 DAY)) and RHD_DRS_ID=3143"); while ($row = mysql_fetch_array($result, MYSQL_NUM)) { $res[] = array( 'id'=> $row[0], 'dev_id'=> $row[1], 'date'=>$row[2], 'hst'=>$row[3], 'hd'=>$row[4], 'q'=>$row[5], 'p1'=>$row[6], 'p2'=>$row[7], 'i'=>$row[8], 'u'=>$row[9], 'pe'=>$row[10], 'cos'=>$row[11], 'pp'=>$row[12], 'hh'=>$row[13], 'dgn'=>$row[14], 'work_time'=>$row[15], 'audit_date'=>$row[16] ); } mysql_free_result($result); echo"Stop: ".date('H:i:s:u')."
"; print_r($res); mysql_close($polacz); ?>