Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

copy a row except an identity column

Status
Not open for further replies.

vincer

Programmer
Mar 12, 2002
45
GB
I have a table with an identity column and under a certain condition I want to change the value in the identity column.

Is there a simple sql statement that I can use regardless of the number of columns, that will insert all but the identity column from another entry in the same table.
Basically I don't want to name the columns in case a new column is added at a later date and the code doesn't get updated.
Many thanks

V
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top