Raised This Month: $32 Target: $400
 8% 

Locking database for non-query functions?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
hlstriker
Green Gaben
Join Date: Mar 2006
Location: OH-IO!
Old 04-14-2013 , 16:52   Locking database for non-query functions?
Reply With Quote #1

Please delete this thread! I'm an idiot and forgot I asked the same thing about a year ago here.

---------------------

Does anyone know if you if you need to lock the database for functions such as SQL_GetInsertId() and SQL_EscapeString()?

The wiki says:
Quote:
Whenever performing any of the following non-threaded operations on a database, it is absolutely necessary to enclose the entire operation with a lock:
SQL_Query() (and SQL_FetchMoreResults pairings)
SQL_FastQuery
SQL_PrepareQuery
SQL_Bind* and SQL_Execute pairings
The rule of thumb is: if your operation is going to use the database connection, it must be locked until the operation is fully completed.
I would like to know for sure.

Last edited by hlstriker; 04-14-2013 at 17:06.
hlstriker is offline
Reply



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 02:40.


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