Raised This Month: $ Target: $400
 0% 

[SOLVED] query not returning results!?


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Sylwester
Veteran Member
Join Date: Oct 2006
Location: Poland
Old 03-22-2011 , 18:12   Re: query not returning results!?
Reply With Quote #6

Do while loop executes check_privs (sends SELECT query), then it moves to the next check_privs (sends SELECT query) and so on. The check to see if there is an entry happens at another time when results are retrieved from database, so the query that inserts data if there are no entries is sent after all SELECT queries from do while loop were sent.

To fix it you can simply concatenate all data that you want to send using do while loop and send it using 1 query.
__________________
Impossible is Nothing
Sylwester is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 14:29.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode