LIMIT 1 - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: LIMIT 1 (
/showthread.php?tid=288206)
LIMIT 1 -
Baboon - 06.10.2011
When should I use LIMIT 1 in mysql?
Thanks.
Re: LIMIT 1 -
dice7 - 06.10.2011
when you only want one result, usualy when getting the biggest/smallest value or something
Re: LIMIT 1 -
Baboon - 06.10.2011
Okay, thanks, do you also know how to delete an user, which is stored in a table?
Re: LIMIT 1 -
TheArcher - 06.10.2011
The syntax for that is
Код:
DELETE FROM "table_name" WHERE {condition}
Re: LIMIT 1 -
TTJJ - 06.10.2011
I would strongly recommend putting "LIMIT 1" at the end of that statement. (If you only want to delete 1 row) I have deleted multiple rows by accident sometimes. Really annoying.