28.10.2012, 17:09
The cache_get_field_content is from BlueG's SQL plugin (see here: https://sampforum.blast.hk/showthread.php?tid=337810)
However, I used cache_get_row rather than cache_get_field_content (which should both do the same thing, but I'm not sure why they didn't, and it worked fine. Here is the code I settled with:
However, I used cache_get_row rather than cache_get_field_content (which should both do the same thing, but I'm not sure why they didn't, and it worked fine. Here is the code I settled with:
pawn Код:
forward loadCars_query();
public loadCars_query()
{
new
rows,
fields;
cache_get_data(rows, fields);
if(rows)
{
new
temp[5],
i,
id;
while(i < rows)
{
cache_get_row(i, 0, temp);
id = strval(temp);
printf("i | rows : %d | %d", id, i, rows);
i++;
}
}
}