-
Couldn't load subscription status.
- Fork 2.5k
Query_sql
Akkarinage edited this page Nov 5, 2016
·
1 revision
- query_sql("your MySQL query"{, {, {, ...}}});
- query_logsql("your MySQL query"{, {, {, ...}}});
Executes an SQL query. A 'select' query can fill array variables with up to 128 rows of values, and will return the number of rows (i.e. array size).
Note that query_sql runs on the main database while query_logsql runs on the log database.
set .@nb, query_sql("SELECT name, fame FROM `char` ORDER BY fame DESC LIMIT 5", .@name$, .@fame);
mes "Hall Of Fame: TOP5";
for(set .@i,1; .@i <= .@nb; set .@i,.@i+1)
mes .@i+". "+.@name$[0]+" ("+.@fame[0]+")"; // Will return a person with the biggest fame value.
- Installation instructions
- Connecting & Starting rAthena
- Scripting like a pro!
- Server Modifications and what to expect
- Database Configuration
- Adding Custom Items
- Adding Custom Monsters
- GRF Encryption
- Data folder
- Diff files