SA-MP Forums Archive
last registered player mysql - 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: last registered player mysql (/showthread.php?tid=490900)



last registered player mysql - COL - 28.01.2014

nvm thx


Re: last registered player mysql - gtakillerIV - 28.01.2014

Well if you use IDs, you can do something like:

Код:
SELECT `Username` FROM `player_table` ORDER BY `ID` DESC LIMIT 1
There's really no need to get all of his data. You just want the username(I guess).


Re: last registered player mysql - COL - 30.01.2014

did not work and I don't use ids


Re: last registered player mysql - Misiur - 30.01.2014

Wait, what? What is your primary key in table? Name? Please attach screenshot of table structure (I hope you use phpmyadmin or some manager like mysql workbench)


Re: last registered player mysql - anou1 - 30.01.2014

Quote:
Originally Posted by gtakillerIV
Посмотреть сообщение
Well if you use IDs, you can do something like:

Код:
SELECT `Username` FROM `player_table` ORDER BY `ID` DESC LIMIT 1
There's really no need to get all of his data. You just want the username(I guess).
Hi,

I don't know how to solve COL's problem but, I want to know how can you extract and use the first username after you selected it.