mismatch error
#2

Hi Hybris,

I used the wiki to get this result (links https://sampwiki.blast.hk/wiki/Db_query https://sampwiki.blast.hk/wiki/Db_free_result).

Try using this code. You may need to replace db_handle with your database handle which should have been defined when you used db_open.
Код:
format(szQuery, sizeof(szQuery), "DELETE FROM bans WHERE name = '%s'", DB_Escape(params));
db_result = db_query(db_handle, szQuery);
db_free_result(db_result);
I would also suggest you read over the wiki for db_query. Please see following extract from the wiki.

db_query(DB:db, query[]);
DB:db The database handle to query.
query[] The query to execute.

I don't think your DB:db (database to handle query) is correct and should not be szQuery. The correct DB:db to use would be where you used:
db_handle = db_open("example.db")
So your db_query should look like this:
db_query(db_handle, szQuery);
Reply


Messages In This Thread
mismatch error - by Hybris - 12.04.2015, 22:47
Re: mismatch error - by MEW273 - 13.04.2015, 08:38
Re: mismatch error - by Hybris - 13.04.2015, 08:56
Re: mismatch error - by MEW273 - 13.04.2015, 09:01

Forum Jump:


Users browsing this thread: 1 Guest(s)