SQLite ... reading strings from database! - 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: SQLite ... reading strings from database! (
/showthread.php?tid=305405)
SQLite ... reading strings from database! -
Edvin - 22.12.2011
Hi there!
I don't know how to read strings for exemple "Testing" in SQLite database.
Exemple:
When player login:
Код:
...
db_get_field_assoc( Result, "Column1", Field, 128 );
P_DATA[ playerid ][ Column1String ] = strlen( Field );
And now using Column1String in a dialog:
Код:
CMD:test( playerid, params[ ] )
{
new str[ 128 ];
format( str, 128, sizeof( str ), "%s", P_DATA[ playerid ][ Column1String ] );
ShowPlayerDialog( playerid ... );
return 1;
}
When i type /test command the dialog is empty...
So ... my question is ... how can i load a string from SQLite database and show it on a dialog

?