MySQL Forums
Forum List  »  Newbie

Re: Looking up a value in a 'subtable' and inserting it if it doesn't exist
Posted by: Dave Kennard
Date: May 06, 2009 08:28AM

I'm using mysqli->multi_query(), so I thought that all the queries would be sent to mysql in one go. But now I think about it, I guess it must do round trips to mysql for each query otherwise how could it fetch a result object for each query. So I'll use the mysqli->insert_id() as you suggest and perform the main table update outside of the multi_query.

Thanks for your help,

Dave

Options: ReplyQuote




Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.