I'm trying to match the points to their names and aid on another table, but somehow the points are not going to their assigned aid, any clues on how to properly set it?
.@sql$ = " SELECT `account_id`,`value` "
+ " FROM `acc_reg_num`"
+ " WHERE `key` = '#s_alltime' "
+ " AND `value` >= 1"
+ " ORDER BY `value` DESC LIMIT 20";
query_sql(.@sql$,.@aid,.@total);
query_sql("SELECT `aid`,`name` FROM `test_db`",.@said,.@name$);
//comparing who's going to be in the ranking
for(.@i = 0; .@i < getarraysize(.@aid); .@i++)
if(inarray(.@said[0],.@aid[.@i]) != -1){
.@all_time$[.@i] = .@name$[inarray(.@aid[0],.@said[.@i])];
.@all_time[.@i] = .@total[inarray(.@aid[0],.@said[.@i])];
}
Question
Nyaniverse
I'm trying to match the points to their names and aid on another table, but somehow the points are not going to their assigned aid, any clues on how to properly set it?
.@sql$ = " SELECT `account_id`,`value` " + " FROM `acc_reg_num`" + " WHERE `key` = '#s_alltime' " + " AND `value` >= 1" + " ORDER BY `value` DESC LIMIT 20"; query_sql(.@sql$,.@aid,.@total); query_sql("SELECT `aid`,`name` FROM `test_db`",.@said,.@name$); //comparing who's going to be in the ranking for(.@i = 0; .@i < getarraysize(.@aid); .@i++) if(inarray(.@said[0],.@aid[.@i]) != -1){ .@all_time$[.@i] = .@name$[inarray(.@aid[0],.@said[.@i])]; .@all_time[.@i] = .@total[inarray(.@aid[0],.@said[.@i])]; }
Link to comment
Share on other sites
1 answer to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.