- marked as major
Console Error from Prepared Statement
Issue #57
resolved
I'm getting duplicate Key error from the prepared statment
PrepareStatement(CHAR_INS_NPCBOT, "INSERT INTO character_npcbot (owner, entry, race, class, istank) VALUES (?, ?, ?, ?, ?)", CONNECTION_ASYNC);
In CharacterDatabase.cpp
I changed the statement to...
PrepareStatement(CHAR_INS_NPCBOT, "REPLACE INTO character_npcbot (owner, entry, race, class, istank) VALUES (?, ?, ?, ?, ?)", CONNECTION_ASYNC);
That seems to have fixed the console error.
Comments (3)
-
repo owner -
repo owner - changed status to open
-
repo owner - changed status to resolved
with 483826deb0 this problem becomes obsolete
- Log in to comment
This is a serious matter, cuz that means some player has summoned bot with same entry twice, this should never happen. I never had such error.
Let's see, It may happen if there is an error in another PS which selects stored npcbots. I think it is the only way to summon npcbot twice.