Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Identity feild in Sybase.

 
MInu
Ranch Hand
Posts: 517
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

I am using Syabseand I have a table that contains one feild set as employee_id numeric(10,0) IDENTITY I need ti update a record to this table with my own empoloyee_id,it will works only after when execute this command
set IDENTITY_INSERT employee_tbl on
That is ok and i insert the row.But i need to update the employee id of one row,like....

update employee_tbl set employee_id=2145 where User_Id='minu'

First I execute the "set IDENTITY_INSERT employee_tbl on" and then i execute the update command,but it show an error like this...

Error: Illegal attempt to update identity field 'employee_id'.

How can i update this record..?? Please anyone help me ...........

Thanks in Advance
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic