You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After updating the plugin, we had to update the database. During the update we git the error message * 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 'option where option_name like '%_isLDAPUser'' at line 1.
After debugging the code, the problem occurs as we use no prefix for the tables and option is a reserved keyword in mysql MySQL Keywords.
After changing the SQL statement, everything went smoothly:
OLD: $optionValues = $db->fetchAll("Select option_name from $optionTable where option_name like '%$searchPattern'");
NEW: $optionValues = $db->fetchAll("Select option_name from `$optionTable` where option_name like '%$searchPattern'");
The text was updated successfully, but these errors were encountered:
After updating the plugin, we had to update the database. During the update we git the error message
* 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 'option where option_name like '%_isLDAPUser'' at line 1
.After debugging the code, the problem occurs as we use no prefix for the tables and option is a reserved keyword in mysql MySQL Keywords.
After changing the SQL statement, everything went smoothly:
OLD: $optionValues = $db->fetchAll("Select option_name from $optionTable where option_name like '%$searchPattern'");
NEW: $optionValues = $db->fetchAll("Select option_name from `$optionTable` where option_name like '%$searchPattern'");
The text was updated successfully, but these errors were encountered: