Thread: [MYSQL]Can anybody see the Syntax error?

Results 1 to 3 of 3
  1. #1 [MYSQL]Can anybody see the Syntax error? 
    Registered Member

    Join Date
    Dec 2007
    Age
    23
    Posts
    318
    Thanks given
    3
    Thanks received
    5
    Rep Power
    88
    i'm using this code:
    Code:
    		String player = "`username` = '" + p.playerName
     + "',`password` = '" + p.playerPass
     + "',`height` =  '" + p.heightLevel
     + "',`Rights` =  '" + p.playerRights
     + "',`x` =  '" + p.absX
     + "',`y` =  '" + p.absY
     + "',`crystal-bow-shots` =  '" + p.crystalBowArrowCount
     + "',`VLS-hits` =  '" + p.degradeTime
     + "',`skull-timer` =  '" + p.skullTimer
     + "',`ag1` =  '" + p.ag1
     + "',`ag2` =  '" + p.ag2
     + "',`ag3` =  '" + p.ag3
     + "',`ag4` =  '" + p.ag4
     + "',`ag5` =  '" + p.ag5
     + "',`ag6` =  '" + p.ag6
     + "',`killcount` =  '" + p.KC
     + "',`deathcount` =  '" + p.DC
     + "',`totalstored` =  '" + p.totalstored
     + "',`used-pure` =  '" + p.pure
     + "',`catChosen` =  '" + p.catChosen
     + "',`has-npc` =  '" + p.hasNpc
     + "',`EP` =  '" + p.earningPotential
     + "',`magic-book` =  '" + p.playerMagicBook
     + "',`special-amount` =  '" + p.specAmount
     + "',`selected-coffin` =  '" + p.randomCoffin
     + "',`barrows-killcount` =  '" + p.barrowsKillCount
     + "',`teleblock-length` =  '" + tbTime
     + "',`pc-points` =  '" + p.pcPoints
     + "',`gwdelay` =  '" + p.gwdelay
     + "',`Altar` =  '" + p.altarPrayed
     + "',`Arma-KC` =  '" + p.Arma
     + "',`Band-KC` =  '" + p.Band
     + "',`Zammy-KC` =  '" + p.Zammy
     + "',`Sara-KC` =  '" + p.Sara
     + "',`pk-points` =  '" + p.pkPoints
     + "',`mb-points` =  '" + p.mbPoints
     + "',`isDonator` =  '" + p.isDonator
     + "',`slayerTask` =  '" + p.slayerTask
     + "',`xpLock` =  '" + p.xpLock
     + "',`Agrith` =  '" + p.Agrith
     + "',`Flambeed` =  '" + p.Flambeed
     + "',`Karamel` =  '" + p.Karamel
     + "',`Dessourt` =  '" + p.Dessourt
     + "',`culin` =  '" + p.Culin
     + "',`taskAmount` =  '" + p.taskAmount
     + "',`magePoints` =  '" + p.magePoints
     + "',`autoRet` =  '" + p.autoRet
     + "',`trade11` =  '" + p.trade11
     + "',`speDelay` =  '" + p.SpecialDelay
     + "',`barrowskillcount` =  '" + p.barrowsKillCount
     + "',`flagged` =  '" + p.accountFlagged
     + "',`Jailed` =  '" + p.Jail
     + "',`wave` =  '" + p.waveId
     + "',`fightMode` =  '" + p.fightMode
     + "',`lastsummon` =  '" + p.lastsummon
     + "',`summoningnpcid` =  '" + p.summoningnpcid
     + "',`Monkey-Kc` =  '" + p.monkeyk0ed
     + "',`void` =  '" + p.voidToDatabase() + "'";
     
     DBConnectionPool.executeUpdate("INSERT INTO player (username, password, height, Rights, x, y, crystal-bow-shots, VLS-hits, skull-timer, ag1, ag2, ag3, ag4, ag5, ag6, killcount, deathcount, totalstored, used-pure, catChosen, has-npc, EP, magic-book, special-amount, selected-coffin, barrows-killcount, teleblock-length, pc-points, gwdelay, Altar, Arma-KC, Band-KC, Zammy-KC, Sara-KC, pk-points, mb-points, isDonator, slayerTask, xpLock, Agrith, Flambeed, Karamel, Dessourt, culin, taskAmount, magePoints, autoRet, trade11, speDelay, barrowskillcount, flagged, Jailed, wave, fightMode, lastsummon, summoningnpcid, Monkey-Kc, void) VALUES ("+player+") ON duplicate KEY UPDATE "+player+"");
     
     String playerData = "'" + p.playerName + "', '"
     + p.skillsToDatabase() + "', '"
     + p.skillsxpToDatabase() + "', '"
     + p.appearanceToDatabase() + "', '"
     + p.itemsToDatabase() + "', '"
     + p.itemNToDatabase() + "', '"
     + p.equipmentToDatabase() + "', '"
     + p.equipmentNToDatabase() + "', '"
     + p.friendsToDatabase() + "', '"
     + p.storedToDatabase() + "', '"
     + p.occupyToDatabase() + "', '"
     + p.brothersToDatabase() + "', '"
     + p.bankToDatabase() + "', '"
     + p.bankNToDatabase() + "'";
     
     DBConnectionPool.executeUpdate("INSERT INTO playerdata (username, skills, skillxp, appearance, item, itemN, equipment, equipmentN, friends, stored, occupy, brother-info, bank, bankN) VALUES ("+playerData+")   ON duplicate KEY UPDATE "+playerData+"");
    There's no compile error.

    Code:
    have an error in your SQL syntax; check the manual that corresponds to your MySQ
    L server version for the right syntax to use near '-info, bank, bankN) VALUES ('
    toxxic', '99:99:99:99:99:99:99:99:99:99:99:99:99:99' at line 1
    [17-9-11 23:02]:        at sun.reflect.NativeConstructorAccessorImpl.newInstance
    0(Native Method)
    [17-9-11 23:02]:        at sun.reflect.NativeConstructorAccessorImpl.newInstance
    (Unknown Source)
    [17-9-11 23:02]:        at sun.reflect.DelegatingConstructorAccessorImpl.newInst
    ance(Unknown Source)
    [17-9-11 23:02]:        at java.lang.reflect.Constructor.newInstance(Unknown Sou
    rce)
    [17-9-11 23:02]:        at com.mysql.jdbc.Util.handleNewInstance(Util.java:406)
    [17-9-11 23:02]:        at com.mysql.jdbc.Util.getInstance(Util.java:381)
    [17-9-11 23:02]:        at com.mysql.jdbc.SQLError.createSQLException(SQLError.j
    ava:1030)
    [17-9-11 23:02]:        at com.mysql.jdbc.SQLError.createSQLException(SQLError.j
    ava:956)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:
    3536)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:
    3468)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1957)
    
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:21
    07)
    [17-9-11 23:02]:        at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.
    java:2642)
    [17-9-11 23:02]:        at com.mysql.jdbc.StatementImpl.executeUpdate(StatementI
    mpl.java:1634)
    [17-9-11 23:02]:        at com.mysql.jdbc.StatementImpl.executeUpdate(StatementI
    mpl.java:1553)
    [17-9-11 23:02]:        at server.DB.DBConnectionPool.executeUpdate(DBConnection
    Pool.java:69)
    [17-9-11 23:02]:        at server.model.players.PlayerSave.saveGame(PlayerSave.j
    ava:248)
    [17-9-11 23:02]:        at server.model.players.PlayerHandler.process(PlayerHand
    ler.java:147)
    [17-9-11 23:02]:        at server.Server.main(Server.java:178)
    [17-9-11 23:02]: Game saved for player toxxic
    [17-9-11 23:02]: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You
    have an error in your SQL syntax; check the manual that corresponds to your MySQ
    L server version for the right syntax to use near '-bow-shots, VLS-hits, skull-t
    imer, ag1, ag2, ag3, ag4, ag5, ag6, killcount, deat' at line 1
    [17-9-11 23:02]:        at sun.reflect.NativeConstructorAccessorImpl.newInstance
    0(Native Method)
    [17-9-11 23:02]:        at sun.reflect.NativeConstructorAccessorImpl.newInstance
    (Unknown Source)
    [17-9-11 23:02]:        at sun.reflect.DelegatingConstructorAccessorImpl.newInst
    ance(Unknown Source)
    [17-9-11 23:02]:        at java.lang.reflect.Constructor.newInstance(Unknown Sou
    rce)
    [17-9-11 23:02]:        at com.mysql.jdbc.Util.handleNewInstance(Util.java:406)
    [17-9-11 23:02]:        at com.mysql.jdbc.Util.getInstance(Util.java:381)
    [17-9-11 23:02]:        at com.mysql.jdbc.SQLError.createSQLException(SQLError.j
    ava:1030)
    [17-9-11 23:02]:        at com.mysql.jdbc.SQLError.createSQLException(SQLError.j
    ava:956)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:
    3536)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:
    3468)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1957)
    
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:21
    07)
    [17-9-11 23:02]:        at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.
    java:2642)
    [17-9-11 23:02]:        at com.mysql.jdbc.StatementImpl.executeUpdate(StatementI
    mpl.java:1634)
    [17-9-11 23:02]:        at com.mysql.jdbc.StatementImpl.executeUpdate(StatementI
    mpl.java:1553)
    [17-9-11 23:02]:        at server.DB.DBConnectionPool.executeUpdate(DBConnection
    Pool.java:69)
    [17-9-11 23:02]:        at server.model.players.PlayerSave.saveGame(PlayerSave.j
    ava:231)
    [17-9-11 23:02]:        at server.model.players.Client.destruct(Client.java:701)
    
    [17-9-11 23:02]:        at server.model.players.PlayerHandler.removePlayer(Playe
    rHandler.java:356)
    [17-9-11 23:02]:        at server.model.players.PlayerHandler.process(PlayerHand
    ler.java:152)
    [17-9-11 23:02]:        at server.Server.main(Server.java:178)
    [17-9-11 23:02]: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You
    have an error in your SQL syntax; check the manual that corresponds to your MySQ
    L server version for the right syntax to use near '-info, bank, bankN) VALUES ('
    toxxic', '99:99:99:99:99:99:99:99:99:99:99:99:99:99' at line 1
    [17-9-11 23:02]:        at sun.reflect.NativeConstructorAccessorImpl.newInstance
    0(Native Method)
    [17-9-11 23:02]:        at sun.reflect.NativeConstructorAccessorImpl.newInstance
    (Unknown Source)
    [17-9-11 23:02]:        at sun.reflect.DelegatingConstructorAccessorImpl.newInst
    ance(Unknown Source)
    [17-9-11 23:02]:        at java.lang.reflect.Constructor.newInstance(Unknown Sou
    rce)
    [17-9-11 23:02]:        at com.mysql.jdbc.Util.handleNewInstance(Util.java:406)
    [17-9-11 23:02]:        at com.mysql.jdbc.Util.getInstance(Util.java:381)
    [17-9-11 23:02]:        at com.mysql.jdbc.SQLError.createSQLException(SQLError.j
    ava:1030)
    [17-9-11 23:02]:        at com.mysql.jdbc.SQLError.createSQLException(SQLError.j
    ava:956)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:
    3536)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:
    3468)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1957)
    
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:21
    07)
    [17-9-11 23:02]:        at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.
    java:2642)
    [17-9-11 23:02]:        at com.mysql.jdbc.StatementImpl.executeUpdate(StatementI
    mpl.java:1634)
    [17-9-11 23:02]:        at com.mysql.jdbc.StatementImpl.executeUpdate(StatementI
    mpl.java:1553)
    [17-9-11 23:02]:        at server.DB.DBConnectionPool.executeUpdate(DBConnection
    Pool.java:69)
    [17-9-11 23:02]:        at server.model.players.PlayerSave.saveGame(PlayerSave.j
    ava:248)
    [17-9-11 23:02]:        at server.model.players.Client.destruct(Client.java:701)
    
    [17-9-11 23:02]:        at server.model.players.PlayerHandler.removePlayer(Playe
    rHandler.java:356)
    [17-9-11 23:02]:        at server.model.players.PlayerHandler.process(PlayerHand
    ler.java:152)
    [17-9-11 23:02]:        at server.Server.main(Server.java:178)
    [17-9-11 23:02]: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You
    have an error in your SQL syntax; check the manual that corresponds to your MySQ
    L server version for the right syntax to use near '-bow-shots, VLS-hits, skull-t
    imer, ag1, ag2, ag3, ag4, ag5, ag6, killcount, deat' at line 1
    [17-9-11 23:02]:        at sun.reflect.NativeConstructorAccessorImpl.newInstance
    0(Native Method)
    [17-9-11 23:02]:        at sun.reflect.NativeConstructorAccessorImpl.newInstance
    (Unknown Source)
    [17-9-11 23:02]:        at sun.reflect.DelegatingConstructorAccessorImpl.newInst
    ance(Unknown Source)
    [17-9-11 23:02]:        at java.lang.reflect.Constructor.newInstance(Unknown Sou
    rce)
    [17-9-11 23:02]:        at com.mysql.jdbc.Util.handleNewInstance(Util.java:406)
    [17-9-11 23:02]:        at com.mysql.jdbc.Util.getInstance(Util.java:381)
    [17-9-11 23:02]:        at com.mysql.jdbc.SQLError.createSQLException(SQLError.j
    ava:1030)
    [17-9-11 23:02]:        at com.mysql.jdbc.SQLError.createSQLException(SQLError.j
    ava:956)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:
    3536)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:
    3468)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1957)
    
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:21
    07)
    [17-9-11 23:02]:        at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.
    java:2642)
    [17-9-11 23:02]:        at com.mysql.jdbc.StatementImpl.executeUpdate(StatementI
    mpl.java:1634)
    [17-9-11 23:02]:        at com.mysql.jdbc.StatementImpl.executeUpdate(StatementI
    mpl.java:1553)
    [17-9-11 23:02]:        at server.DB.DBConnectionPool.executeUpdate(DBConnection
    Pool.java:69)
    [17-9-11 23:02]:        at server.model.players.PlayerSave.saveGame(PlayerSave.j
    ava:231)
    [17-9-11 23:02]:        at server.model.players.Client.destruct(Client.java:702)
    
    [17-9-11 23:02]:        at server.model.players.PlayerHandler.removePlayer(Playe
    rHandler.java:356)
    [17-9-11 23:02]:        at server.model.players.PlayerHandler.process(PlayerHand
    ler.java:152)
    [17-9-11 23:02]:        at server.Server.main(Server.java:178)
    [17-9-11 23:02]: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You
    have an error in your SQL syntax; check the manual that corresponds to your MySQ
    L server version for the right syntax to use near '-info, bank, bankN) VALUES ('
    toxxic', '99:99:99:99:99:99:99:99:99:99:99:99:99:99' at line 1
    [17-9-11 23:02]:        at sun.reflect.NativeConstructorAccessorImpl.newInstance
    0(Native Method)
    [17-9-11 23:02]:        at sun.reflect.NativeConstructorAccessorImpl.newInstance
    (Unknown Source)
    [17-9-11 23:02]:        at sun.reflect.DelegatingConstructorAccessorImpl.newInst
    ance(Unknown Source)
    [17-9-11 23:02]:        at java.lang.reflect.Constructor.newInstance(Unknown Sou
    rce)
    [17-9-11 23:02]:        at com.mysql.jdbc.Util.handleNewInstance(Util.java:406)
    [17-9-11 23:02]:        at com.mysql.jdbc.Util.getInstance(Util.java:381)
    [17-9-11 23:02]:        at com.mysql.jdbc.SQLError.createSQLException(SQLError.j
    ava:1030)
    [17-9-11 23:02]:        at com.mysql.jdbc.SQLError.createSQLException(SQLError.j
    ava:956)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:
    3536)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:
    3468)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1957)
    
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:21
    07)
    [17-9-11 23:02]:        at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.
    java:2642)
    [17-9-11 23:02]:        at com.mysql.jdbc.StatementImpl.executeUpdate(StatementI
    mpl.java:1634)
    [17-9-11 23:02]:        at com.mysql.jdbc.StatementImpl.executeUpdate(StatementI
    mpl.java:1553)
    [17-9-11 23:02]:        at server.DB.DBConnectionPool.executeUpdate(DBConnection
    Pool.java:69)
    [17-9-11 23:02]:        at server.model.players.PlayerSave.saveGame(PlayerSave.j
    ava:248)
    [17-9-11 23:02]:        at server.model.players.Client.destruct(Client.java:702)
    
    [17-9-11 23:02]:        at server.model.players.PlayerHandler.removePlayer(Playe
    rHandler.java:356)
    [17-9-11 23:02]:        at server.model.players.PlayerHandler.process(PlayerHand
    ler.java:152)
    [17-9-11 23:02]:        at server.Server.main(Server.java:178)
    [17-9-11 23:02]: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You
    have an error in your SQL syntax; check the manual that corresponds to your MySQ
    L server version for the right syntax to use near '-bow-shots, VLS-hits, skull-t
    imer, ag1, ag2, ag3, ag4, ag5, ag6, killcount, deat' at line 1
    [17-9-11 23:02]:        at sun.reflect.NativeConstructorAccessorImpl.newInstance
    0(Native Method)
    [17-9-11 23:02]:        at sun.reflect.NativeConstructorAccessorImpl.newInstance
    (Unknown Source)
    [17-9-11 23:02]:        at sun.reflect.DelegatingConstructorAccessorImpl.newInst
    ance(Unknown Source)
    [17-9-11 23:02]:        at java.lang.reflect.Constructor.newInstance(Unknown Sou
    rce)
    [17-9-11 23:02]:        at com.mysql.jdbc.Util.handleNewInstance(Util.java:406)
    [17-9-11 23:02]:        at com.mysql.jdbc.Util.getInstance(Util.java:381)
    [17-9-11 23:02]:        at com.mysql.jdbc.SQLError.createSQLException(SQLError.j
    ava:1030)
    [17-9-11 23:02]:        at com.mysql.jdbc.SQLError.createSQLException(SQLError.j
    ava:956)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:
    3536)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:
    3468)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1957)
    
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:21
    07)
    [17-9-11 23:02]:        at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.
    java:2642)
    [17-9-11 23:02]:        at com.mysql.jdbc.StatementImpl.executeUpdate(StatementI
    mpl.java:1634)
    [17-9-11 23:02]:        at com.mysql.jdbc.StatementImpl.executeUpdate(StatementI
    mpl.java:1553)
    [17-9-11 23:02]:        at server.DB.DBConnectionPool.executeUpdate(DBConnection
    Pool.java:69)
    [17-9-11 23:02]:        at server.model.players.PlayerSave.saveGame(PlayerSave.j
    ava:231)
    [17-9-11 23:02]:        at server.model.players.Client.destruct(Client.java:711)
    
    [17-9-11 23:02]:        at server.model.players.PlayerHandler.removePlayer(Playe
    rHandler.java:356)
    [17-9-11 23:02]:        at server.model.players.PlayerHandler.process(PlayerHand
    ler.java:152)
    [17-9-11 23:02]:        at server.Server.main(Server.java:178)
    [17-9-11 23:02]: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You
    have an error in your SQL syntax; check the manual that corresponds to your MySQ
    L server version for the right syntax to use near '-info, bank, bankN) VALUES ('
    toxxic', '99:99:99:99:99:99:99:99:99:99:99:99:99:99' at line 1
    [17-9-11 23:02]:        at sun.reflect.NativeConstructorAccessorImpl.newInstance
    0(Native Method)
    [17-9-11 23:02]:        at sun.reflect.NativeConstructorAccessorImpl.newInstance
    (Unknown Source)
    [17-9-11 23:02]:        at sun.reflect.DelegatingConstructorAccessorImpl.newInst
    ance(Unknown Source)
    [17-9-11 23:02]:        at java.lang.reflect.Constructor.newInstance(Unknown Sou
    rce)
    [17-9-11 23:02]:        at com.mysql.jdbc.Util.handleNewInstance(Util.java:406)
    [17-9-11 23:02]:        at com.mysql.jdbc.Util.getInstance(Util.java:381)
    [17-9-11 23:02]:        at com.mysql.jdbc.SQLError.createSQLException(SQLError.j
    ava:1030)
    [17-9-11 23:02]:        at com.mysql.jdbc.SQLError.createSQLException(SQLError.j
    ava:956)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:
    3536)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:
    3468)
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1957)
    
    [17-9-11 23:02]:        at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:21
    07)
    [17-9-11 23:02]:        at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.
    java:2642)
    [17-9-11 23:02]:        at com.mysql.jdbc.StatementImpl.executeUpdate(StatementI
    mpl.java:1634)
    [17-9-11 23:02]:        at com.mysql.jdbc.StatementImpl.executeUpdate(StatementI
    mpl.java:1553)
    [17-9-11 23:02]:        at server.DB.DBConnectionPool.executeUpdate(DBConnection
    Pool.java:69)
    [17-9-11 23:02]:        at server.model.players.PlayerSave.saveGame(PlayerSave.j
    ava:248)
    [17-9-11 23:02]:        at server.model.players.Client.destruct(Client.java:711)
    
    [17-9-11 23:02]:        at server.model.players.PlayerHandler.removePlayer(Playe
    rHandler.java:356)
    [17-9-11 23:02]:        at server.model.players.PlayerHandler.process(PlayerHand
    ler.java:152)
    [17-9-11 23:02]:        at server.Server.main(Server.java:178)
    thanks in advance!
    Reply With Quote  
     

  2. #2  
    Registered Member
    Polaroid's Avatar
    Join Date
    Jul 2009
    Posts
    936
    Thanks given
    1,088
    Thanks received
    63
    Rep Power
    94
    Code:
     + p.bankToDatabase() + "', '"
     + p.bankNToDatabase() + "'";
    why is the bottom one different to ALL the others?
    Reply With Quote  
     

  3. #3  
    Registered Member

    Join Date
    Dec 2007
    Age
    23
    Posts
    318
    Thanks given
    3
    Thanks received
    5
    Rep Power
    88
    Quote Originally Posted by Polaroid View Post
    Code:
     + p.bankToDatabase() + "', '"
     + p.bankNToDatabase() + "'";
    why is the bottom one different to ALL the others?
    because it's the last one, so you don't need to place a , because theres comming nothing more.
    Reply With Quote  
     


Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Similar Threads

  1. Mysql default jdbc Syntax?
    By Rskings_1337 in forum Help
    Replies: 2
    Last Post: 06-28-2011, 09:35 AM
  2. Replies: 6
    Last Post: 09-15-2010, 04:20 PM
  3. Syntax
    By 'Connor in forum Help
    Replies: 2
    Last Post: 07-14-2010, 03:39 PM
  4. [PHP-MySQL] Error in your SQL syntax.
    By Coombser in forum Help
    Replies: 4
    Last Post: 02-06-2010, 11:18 AM
  5. XML Syntax
    By Sub in forum Application Development
    Replies: 4
    Last Post: 06-05-2008, 06:39 PM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •