MyBB Community Forums

Full Version: Default Value - mybb_mysubs
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
1364 - Field 'order' doesn't have a default value

I tried doing this command - 

alter table mybb_mysubs alter order set default 0;
ERROR 1064 (42000): 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 'order set default 0' at line 1
I recommend you google SQL Queries before trying to run them.

'order' is a reserved keyword, and therefore is not interpreted as a 'column' like how you see it.

You would have to enclose it in single brackets or like this order, as such, it would look similar to:
ALTER TABLE mybb_mysubs ALTER `order` SET DEFAULT 0;