Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.Original topic: tidb表创建之后能不能创建id自增主键?

Version: v5.3.0
After creating a table, can you alter an auto_increment primary key?
Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.Original topic: tidb表创建之后能不能创建id自增主键?
Version: v5.3.0
After creating a table, can you alter an auto_increment primary key?
It’s rare to see such an easy question. Search the documentation before asking
You need to read the official documentation… Are you using TiDB without even looking at the documentation?
Is there any other way to add it? Or do I have to rebuild the table?
Take a look at whether the section _tidb_rowid on the table meets your requirements.
TiCDC synchronization requires a primary key or unique index, not an auto-increment primary key.
This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.