View Single Post
devicenull
Veteran Member
Join Date: Mar 2004
Location: CT
Old 08-24-2004 , 13:30  
Reply With Quote #17

Kamikaze: Mysql, create your sql connection variable like this
Code:
new Sql:sql
Where the second sql is the variable name, just like floats and stuff

Also, this would be nice to put in amxmisc or dbi
Code:
stock init_sql(Sql:db) {     new host[64], username[32], password[32], dbname[32], error[32]     get_cvar_string("amx_sql_host",host,64)     get_cvar_string("amx_sql_user",username,32)     get_cvar_string("amx_sql_pass",password,32)     get_cvar_string("amx_sql_db",dbname,32)     db = dbi_connect(host,username,password,dbname,error,31)     if (db == SQL_FAILED) {         return -1     } return 1 }
__________________
Various bits of semi-useful code in a bunch of languages: http://code.devicenull.org/
devicenull is offline