mysql_function_query new
#1

How to write mysql_function_query today? (newest mysql plugin)

And how to turn cache to True / False ?
Reply
#2

You should update to the R40 version, you can follow my tutorial if you wish. Nowadays the MySQL plugin uses threaded queries, the functions are mysql_tquery and mysql_pquery. Queries sent with mysql_tquery are queued and they execute in the order you send them. On the other hand, mysql_pquery queries run at once.
PHP код:
// mysql_tquery
mysql_tquery(db_handle"SELECT * FROM `vehicles`"OnVehiclesLoad); // The vehicles load first.
mysql_tquery(db_handle"SELECT * FROM `houses`"OnHousesLoad); // The houses load after the vehicles. 
PHP код:
// mysql_pquery
mysql_pquery(db_handle"SELECT * FROM `vehicles`"OnVehiclesLoad);
mysql_pquery(db_handle"SELECT * FROM `houses`"OnHousesLoad);
// In this case the houses might load before the vehicles, you can't control the execution order here. 
Despite the above, you can still use unthreaded queries making use of mysql_query. In my opinion, you shoud use threaded queries along with the cache functions.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)