mysql help
#1

why i'm getting this thing and after my server closes? this is from debug:

Код:
[18:39:28] CMySQLHandler::Query(SELECT * FROM `blabla` WHERE id='10') - Successfully executed.

[18:39:28] >> mysql_store_result( Connection handle: 1 )

[18:39:28] CMySQLHandler::StoreResult() - Result was stored.

[18:39:28] >> mysql_fetch_row_format( Connection handle: 1 )

[18:39:28] >> mysql_free_result( Connection handle: 1 )

[18:39:28] CMySQLHandler::FreeResult() - Result was successfully free'd.

[18:39:28] >> mysql_connect( )

[18:39:28] CMySQLHandler::Connect() - Connection was successful.

[18:39:28] CMySQLHandler::Connect() - Auto-Reconnect has been enabled.

[18:39:28] >> mysql_ping( Connection handle: 1 )

[18:39:28] CMySQLHandler::Ping() - Connection is still alive.

[18:39:28] >> mysql_close( Connection handle: 1 )

[18:39:28] CMySQLHandler::~CMySQLHandler() - deconstructor called.

[18:39:28] CMySQLHandler::FreeResult() - The result is already empty.

[18:39:28] CMySQLHandler::Disconnect() - Connection was closed.
I don't have disconnect anywhere..

my code:

pawn Код:
public LoadFactions( ) {
    for( new i = 1; i <= MAX_FACTIONS; i++ ) {
        MySQLCheckConnection( );
        new string[ 256 ];
        format( string, sizeof string,"SELECT * FROM `factions` WHERE id='%d'", i );
        mysql_query( string );
        mysql_store_result( );
        new field[ 64 ], data[ 256 ];
        if(mysql_fetch_row_format( data ) )
        {
            mysql_fetch_field_row( field, "Name" ); format( F_DATA[ i ][ FName ], 64, "%s", field );
            mysql_fetch_field_row( field, "X" ); F_DATA[ i ][ Xf ] = floatstr( field );
            mysql_fetch_field_row( field, "Y" ); F_DATA[ i ][ Yf ] = floatstr( field );
            mysql_fetch_field_row( field, "Z" ); F_DATA[ i ][ Zf ] = floatstr( field );
            mysql_fetch_field_row( field, "A" ); F_DATA[ i ][ Af ] = floatstr( field );
            mysql_fetch_field_row( field, "Interior" ); F_DATA[ i ][ Interior ] = strval( field );
            mysql_fetch_field_row( field, "FMoney" ); F_DATA[ i ][ FMoney ] = strval( field );
            mysql_fetch_field_row( field, "FDrugs" ); F_DATA[ i ][ FDrugs ] = strval( field );
            mysql_fetch_field_row( field, "FMaterials" ); F_DATA[ i ][ FMaterials ] = strval( field );
            mysql_fetch_field_row( field, "FLeaderSkin" ); F_DATA[ i ][ FLeaderSkin ] = strval( field );
            mysql_fetch_field_row( field, "FSkin1" ); F_DATA[ i ][ FSkin1 ] = strval( field );
            mysql_fetch_field_row( field, "FSkin2" ); F_DATA[ i ][ FSkin2 ] = strval( field );
            mysql_fetch_field_row( field, "FSkin3" ); F_DATA[ i ][ FSkin3 ] = strval( field );
            mysql_fetch_field_row( field, "FSkin4" ); F_DATA[ i ][ FSkin4 ] = strval( field );
            mysql_fetch_field_row( field, "FSkin5" ); F_DATA[ i ][ FSkin5 ] = strval( field );
        }
        mysql_free_result( );
        printf("Faction: %d, LSKIN: %d", i, F_DATA[ i ][ FLeaderSkin ]);
    }
    return true;
}
Reply


Messages In This Thread
mysql help - by fordawinzz - 30.09.2011, 15:36
Re: mysql help - by Retardedwolf - 01.10.2011, 11:13
Re: mysql help - by fordawinzz - 01.10.2011, 13:58
Re: mysql help - by Retardedwolf - 01.10.2011, 21:32
Re: mysql help - by fordawinzz - 02.10.2011, 08:20

Forum Jump:


Users browsing this thread: 1 Guest(s)