SA-MP Forums Archive
String size, more than 2048? - 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: String size, more than 2048? (/showthread.php?tid=462161)



String size, more than 2048? - Army - 05.09.2013

Hello, i have MySQL query, but i need to use more than 2048 characters, is it possible, how?


Re: String size, more than 2048? - Borg - 05.09.2013

Try to use global variable with this size


Re: String size, more than 2048? - newbienoob - 05.09.2013

Can I see the query?


Re: String size, more than 2048? - Army - 05.09.2013

Quote:
Originally Posted by Borg
Посмотреть сообщение
Try to use global variable with this size
I think it does not help me.

Quote:
Originally Posted by newbienoob
Посмотреть сообщение
Can I see the query?
It's normal update query, there is no way to make it shorter. It have about 100 variables and all variables needs values. If you have solution, please tell.


Re: String size, more than 2048? - Isolated - 05.09.2013

Use strcat.
https://sampwiki.blast.hk/wiki/Strcat

I'll show you query of mine if needed, just PM me.


Re: String size, more than 2048? - Borg - 05.09.2013

Try to use 2 queries instead of 1


Re: String size, more than 2048? - Emmet_ - 05.09.2013

Yes, it's possible. Pawn can create any string size, as long as the computer the script is being compiled on has enough memory to process those cells (remember, 2048 cells is 8192 bytes, around 8 kb).

Start by adding 128 to the string size each time until your queries are perfectly in size and execute correctly.


Re: String size, more than 2048? - Vince - 05.09.2013

Quote:
Originally Posted by Army
Посмотреть сообщение
no way to make it shorter. It have about 100 variables
A single table should not contain more than about two dozen fields. Put player information in a separate table, character information in a separate table, weapons in a separate table, vehicles in a separate table, etc.