09-11-2010, 01:16 PM
добрый день, подскажите как исправить такую ошибку никак не могу понять
Код:
ERROR [11 сен 2010 14:17:32,187] com.aionemu.commons.database.DB:453 Can't execute update for PreparedStatement
com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException: Cannot delete or update a parent row: a foreign key constraint fails (`al_server_gs`.`abyss_rank`, CONSTRAINT `abyss_rank_ibfk_1` FOREIGN KEY (`player_id`) REFERENCES `players` (`id`))
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at com.mysql.jdbc.Util.handleNewInstance(Util.java:409)
at com.mysql.jdbc.Util.getInstance(Util.java:384)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1041)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3566)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3498)
at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1959)
at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2113)
at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2568)
at com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:2113)
at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2409)
at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2327)
at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2312)
at org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:105)
at org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:105)
at com.aionemu.commons.database.DB.executeUpdate(DB.java:449)
at com.aionemu.commons.database.DB.executeUpdateAndClose(DB.java:467)
at mysql5.MySQL5PlayerDAO.deletePlayer(MySQL5PlayerDAO.java from JavaSourceFromFile:322)
at com.aionemu.gameserver.services.PlayerService.deletePlayerFromDB(PlayerService.java:483)
at com.aionemu.gameserver.services.AccountService.removeDeletedCharacters(AccountService.java:104)
at com.aionemu.gameserver.services.AccountService.getAccount(AccountService.java:83)
at com.aionemu.gameserver.network.loginserver.LoginServer.accountAuthenticationResponse(LoginServer.java:246)
at com.aionemu.gameserver.network.loginserver.clientpackets.CM_ACOUNT_AUTH_RESPONSE.runImpl(CM_ACOUNT_AUTH_RESPONSE.java:94)
at com.aionemu.gameserver.network.loginserver.LsClientPacket.run(LsClientPacket.java:53)
at com.aionemu.commons.utils.concurrent.ExecuteWrapper.execute(ExecuteWrapper.java:61)
at com.aionemu.commons.utils.concurrent.ExecuteWrapper.run(ExecuteWrapper.java:42)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)