MySQL cannot allow creating a table with column name DB_ROW_ID

I have a database in MySQL that uses the InnoDB engine. When I create a table with column name DB_ROW_ID. the error message does not allow you to create a table with the column name DB_ROW_ID. Why?

+7
mysql
source share
1 answer

You cannot create a table with a column name that matches the name of the InnoDB internal column (including DB_ROW_ID, DB_TRX_ID, DB_ROLL_PTR, and DB_MIX_ID). This restriction applies to the use of names in any case letters.

mysql> CREATE TABLE t1 (c1 INT, db_row_id INT) ENGINE = INNODB; ERROR 1166 (42000): Invalid column name 'db_row_id'

+5
source share

All Articles