SA-MP Forums Archive
[Help] MySQL - 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: [Help] MySQL (/showthread.php?tid=336090)



[Help] MySQL - BLAbla93 - 21.04.2012

I would like to thank everyone ahead of time, that helps in this issue, and for the record I am still new to SQL.
So I have 4 rows in my table but when I am looping through it skips every other row.

Here is a simple version of my code:
pawn Код:
mysql_store_result();
    printf("%d", mysql_num_rows());

    while(mysql_retrieve_row())
    {
        mysql_fetch_row_format(resultline);
        print(resultline);
    }
    mysql_free_result();

Here is the console output:
Код:
[21:10:09] 4
[21:10:09] Government|500|5|1|2514.22|-1691.5|14.046|1 //<- 2nd row in the table
[21:10:09] Government|10500|6|1|2524.71|-1658.63|15.824|6.4 //<- 4th row in the table
If you have any ideas please say so or for ever hold your thought.

I am using BlueG' plugin.


Re: [Help] MySQL - BLAbla93 - 22.04.2012

Resolved, figured it out.