matcracker / BedcoreProtect

BedcoreProtect is a fast, efficient, data logging and anti-griefing tool for PocketMine servers. Rollback and restore any amount of damage.
https://poggit.pmmp.io/p/BedcoreProtect/
GNU General Public License v3.0
43 stars 8 forks source link

Problem occurs when approaching mysql #76

Closed cherrychip8293 closed 1 year ago

cherrychip8293 commented 1 year ago

Fatal error: Uncaught mysqli_sql_exception: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '"log_history" (log_id) ON DELETE CASCADE )' at line 5 in phar:///home/user/pm/plugins/BedcoreProtect.phar/src/matcracker/BedcoreProtect/libs/poggit/libasynql/mysqli/MysqliThread.php:115 Stack trace:

0 phar:///home/user/pm/plugins/BedcoreProtect.phar/src/matcracker/BedcoreProtect/libs/poggit/libasynql/mysqli/MysqliThread.php(115): mysqli->query('CREATE TABLE IF...')

1 phar:///home/user/pm/plugins/BedcoreProtect.phar/src/matcracker/BedcoreProtect/libs/poggit/libasynql/base/SqlSlaveThread.php(86): matcracker\BedcoreProtect\libs\poggit\libasynql\mysqli\MysqliThread->executeQuery(Object(mysqli), 0, 'CREATE TABLE IF...', Array)

2 phar:///home/user/pm/PocketMine-MP.phar/src/thread/CommonThreadPartsTrait.php(96): matcracker\BedcoreProtect\libs\poggit\libasynql\base\SqlSlaveThread->onRun()

3 [internal function]: pocketmine\thread\Thread->run()

4 {main}

thrown in phar:///home/user/pm/plugins/BedcoreProtect.phar/src/matcracker/BedcoreProtect/libs/poggit/libasynql/mysqli/MysqliThread.php on line 115

Checked all database storage locations, etc., but error not resolved

matcracker commented 1 year ago

My bad, I copy and paste the same SQL query between SQLite and MySQL. I'll fix the issue ASAP.

cherrychip8293 commented 1 year ago

It hasn't been solved yet

Fatal error: Uncaught mysqli_sql_exception: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '"log_history" (log_id) ON DELETE CASCADE )' at line 5 in /home/user/pm/plugins/BedcoreProtect/src/matcracker/BedcoreProtect/libs/poggit/libasynql/mysqli/MysqliThread.php:115 Stack trace:

0 /home/user/pm/plugins/BedcoreProtect/src/matcracker/BedcoreProtect/libs/poggit/libasynql/mysqli/MysqliThread.php(115): mysqli->query('CREATE TABLE IF...')

1 /home/user/pm/plugins/BedcoreProtect/src/matcracker/BedcoreProtect/libs/poggit/libasynql/base/SqlSlaveThread.php(86): matcracker\BedcoreProtect\libs\poggit\libasynql\mysqli\MysqliThread->executeQuery(Object(mysqli), 0, 'CREATE TABLE IF...', Array)

2 phar:///home/user/pm/PocketMine-MP.phar/src/thread/CommonThreadPartsTrait.php(96): matcracker\BedcoreProtect\libs\poggit\libasynql\base\SqlSlaveThread->onRun()

3 [internal function]: pocketmine\thread\Thread->run()

4 {main}

thrown in /home/user/pm/plugins/BedcoreProtect/src/matcracker/BedcoreProtect/libs/poggit/libasynql/mysqli/MysqliThread.php on line 115

matcracker commented 1 year ago

Did you try with build 529? https://poggit.pmmp.io/ci/matcracker/BedcoreProtect/BedcoreProtect/dev:529