Mysql help
#1

PHP код:
case DIALOG_REGISTER:
        {
            if(!
response) return Kick(playerid);
            if(
strlen(inputtext) < 6) return ShowPlayerDialog(playeridDIALOG_REGISTERDIALOG_STYLE_INPUT"Registration""{FFFFFF}Your account does not exist. Please register below\nbefore playing so your statistics save.\n\nYour password must be at least {F05151}6 characters{FFFFFF} long!""Next""Quit");
            
WP_Hash(Player[playerid][Pass], 129inputtext); //hashing inputtext
            
Logged[playerid] = true;
            
Newreg[playerid] = true;
            
mysql_format(mysqlquerysizeof(query), "INSERT INTO `players` (`ID`, `User`, `Pass`, `IP`, `Admin`, `SkinID`, `AccountLocked`, `AccountBanned`, `BanningAdmin`, `BannedReason`, `MoneyHand`, `MoneyBank`,`Health`, `Armour`, `LastActivity`, `WeaponSlot1`, `WepSlotAmmo1`, `WeaponSlot2`, `WepSlotAmmo2`, `WeaponSlot3`, `WepSlotAmmo3`, `WeaponSlot4`, `WepSlotAmmo4`, `WeaponSlot5`, `WepSlotAmmo5`) VALUES ('', '%e', '%s', '%s', 0, 299, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 250, 5000, 0, 0, 0, 100.0, 0.0, 0, 0)"GetUserName(playerid), Player[playerid][Pass], IP[playerid]);
            
mysql_tquery(mysqlquery"CreateUser""i"playerid);
        }
    }
    return 
false
PHP код:
Line no 212mysql_format(mysqlquerysizeof(query), "INSERT INTO `players` (`ID`, `User`, `Pass`, `IP`, `Admin`, `SkinID`, `AccountLocked`, `AccountBanned`, `BanningAdmin`, `BannedReason`, `MoneyHand`, `MoneyBank`,`Health`, `Armour`, `LastActivity`, `WeaponSlot1`, `WepSlotAmmo1`, `WeaponSlot2`, `WepSlotAmmo2`, `WeaponSlot3`, `WepSlotAmmo3`, `WeaponSlot4`, `WepSlotAmmo4`, `WeaponSlot5`, `WepSlotAmmo5`) VALUES ('', '%e', '%s', '%s', 0, 299, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 250, 5000, 0, 0, 0, 100.0, 0.0, 0, 0)"GetUserName(playerid), Player[playerid][Pass], IP[playerid]); 
PHP код:
(211) : error 075input line too long (after substitutions)
212) : error 037invalid string (possibly non-terminated string)
(
212) : error 017undefined symbol "INSERT"
(212) : error 017undefined symbol "INTO"
(212) : fatal error 107too many error messages on one line 
Help me. I got this script somewhere and im trying to compile it but i get this error.
Reply
#2

Someone help me? as fast as you can. I need it
Reply
#3

You are only inserting 3 actual values so set up default values in your table so you don't have to write unnecessarily long queries. The compiler is complaining because your line is too long (which you could've guessed by reading the message).
Reply
#4

Quote:
Originally Posted by Vince
Посмотреть сообщение
You are only inserting 3 actual values so set up default values in your table so you don't have to write unnecessarily long queries. The compiler is complaining because your line is too long (which you could've guessed by reading the message).
Ah thanks, Can you give me some codes? Im noob but i like to learn mysql so.
Reply
#5

i need it fast
Reply
#6

Someone help i need it please. I'm sorry for bumping but i need it. Can someone fix it?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)