db-sync icon indicating copy to clipboard operation
db-sync copied to clipboard

Error if using a column that is not id as primary key

Open sayajin101 opened this issue 6 years ago • 1 comments

I have found an issue, that if I set a different column as the primary key, it says that the MySQL syntax is incorrect.

[info] Hash calculation:

CONCAT(COALESCE(LOWER(CONV(BIT_XOR(CAST(CONV(SUBSTR(MD5(CONCAT_WS('#', `username`, `groupname`, `priority`)),17,16),16,10) AS UNSIGNED)), 10, 16)), 0),COALESCE(LOWER(CONV(BIT_XOR(CAST(CONV(SUBSTR(MD5(CONCAT_WS('#', `username`, `groupname`, `priority`)),1,16),16,10) AS UNSIGNED)), 10, 16)), 0))

SQLSTATE[42000]: Syntax error or access violation: 1064 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 ') < ()) t limit 1' at line 1

sayajin101 avatar Oct 15 '18 16:10 sayajin101

Same here. It seems to be a bug. Did you find a workaround?

afeno avatar Jun 03 '21 05:06 afeno