ahiad hazan
ahiad hazan

Reputation: 23

Migrate SQL users table but keep their original id's

How to copy users table between wordpress databases but keep their original id from the origin table?

when I export -> import users to a new table, the new id's are written incrementally instead of getting the original id's

I expect user id 567 in the new table to get the user id 567 in the new table even though there are no users in id numbers 2 to 566.

Upvotes: 0

Views: 152

Answers (1)

ahiad hazan
ahiad hazan

Reputation: 23

when you export you database via phpmyadmin, in the "Object creation options" you can tick off the "auto_increment value" to export the database in the original id's as the table you are exporting.

Upvotes: 1

Related Questions