How could I ? [mysql]
#3

Before you ban try this(Simple Way):
Quote:

SELECT Username FROM 'your_table' WHERE Username='PLAYERNAME'

Then use mysql_num_rows to get if any row exists.
If it returns 0 then the user doesn't exist.

Or check after you send the BAN query.If it returns a value then the player has been banned or else nothing happens to the database and you'll come to know that user doesn't exist.This method eliminates an additional query.
Reply


Messages In This Thread
How could I ? [mysql] - by anou1 - 09.02.2014, 20:31
Re: How could I ? [mysql] - by anou1 - 10.02.2014, 07:34
Re: How could I ? [mysql] - by Yashas - 10.02.2014, 08:16
Re: How could I ? [mysql] - by anou1 - 10.02.2014, 08:48
Re: How could I ? [mysql] - by SwisherSweet - 10.02.2014, 08:52
Re: How could I ? [mysql] - by anou1 - 10.02.2014, 09:03
Re: How could I ? [mysql] - by SwisherSweet - 10.02.2014, 09:04
Re: How could I ? [mysql] - by anou1 - 10.02.2014, 09:08
Re: How could I ? [mysql] - by SwisherSweet - 10.02.2014, 09:10
Re: How could I ? [mysql] - by Konstantinos - 10.02.2014, 09:51

Forum Jump:


Users browsing this thread: 1 Guest(s)