Skip to content
Advertisement

How to make a copied data, then insert back and update the values in one column, id will be auto-increment in the same table?

Table Car

Table Car

Copy the first 5 data, insert back and set new VIN values for copied data, id will be auto-increment

Advertisement

Answer

If id is an identity or auto increment column (or something comparable), you can use:

Not sure what “update the VIN” is supposed to be though.

User contributions licensed under: CC BY-SA
4 People found this is helpful
Advertisement