runtime error mysql +Rep
#1

well,i have made a command to store 800 things in the database using a loop,i mean i used the command to insert 800 things,when i type the command it does around 562 and stops and shows runtime error,why?
pawn Код:
CMD:test(playerid)
{
    new query[168];
    for(new n = 0; n < 750; n++)
    {
                        mysql_format(dbHandle, query, sizeof(query), "INSERT INTO `thing` \
                        (`num`, `crea`, `done`, `amount`, `gun1`, `gun2`, `gun3`, `gun4`, `gun5`, `gun6`, `gun7`, `gun8`, `gun9`, `valid`) \
                        VALUES (%d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d)"
, n, info[1][num][n], info[1][num2][n], info[1][num3][n], info[1][num4][n], 0info[1][num5][n] info[1][num6][n], info[1][num7][n], info[1][num8][n], info[1][num9][n], info[1][num10][n], info[1][num11][n], info[1][num12][n], info[1][num13][n]);
                        mysql_tquery(mysql, query, "", "");
    }
    return 1;
}
NOTE:I used packed string for the enum of this system
Reply
#2

show the enum
Reply
#3

Probably there's a data that it is not sent correctly or that doesn't match.
If i were you i would tighten my search area, and just try to find the number of that precise data and then check.
And the MySQL log please.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)