I am currently facing this issue that i never came accross.
When i run SQL query directly from PHPMyAdmin it shows total of 5 rows of 5 rows of data. However when i run this same query from a php script it shows only 2 rows out of 5.
its same sql code but not sure why its showing less data.
I have tried to restart mysql database but did not resolve the issue.
This is the SQL code.
$today = date("Y-m-d");
Select `pwd_orders_new`.*, SUM(item_price*qty) AS 'Total' From `pwd_orders_new` WHERE txn_id <> '' AND DATE(`adddate`) = '$today' GROUP BY txn_id ORDER BY `pwd_orders_new`.`id` DESC LIMIT 0,20000
PHP CODE:
$_dbObj= new EPOS(DBHOST,DBNAME,DBPW,DBNAME);
$table = $_dbObj->get_orders_onList($id);
while($row = mysqli_fetch_assoc($table)){
$rows['orders'][] =$row;
}
print_r(json_encode($rows));
Any help?