mysql - mysqli_multi_query() statements executed parallel or one after another? -
i executing mysqli_multi_query() 2 queries in it:
update customers set balance = balance + 15 ck in (select ck purchases deal_id = 1 , status = 0); update purchases set status = 3 deal_id = 1;
before executing queries - there several records in purchases table status=0, customers table not receive updates reason. tested running both queries hand 1 after - works. have feeling second update runs before first one. shouldn't go 1 after without processing @ same time?
thanks
the queries executed 1 after another, , it's case long queries queued via single mysql connection.
i have feeling not handling results correctly. need call mysqli_store_result() once after multi query , while mysqli_more_results() mysqli_next_result().
Comments
Post a Comment