Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 problem regarding UPDATE

Author  Topic 

lamiajoyee
Starting Member

15 Posts

Posted - 2012-01-17 : 05:39:56
i want to increment the current salary of employees by adding some overtime fees. im trying to accomplish this by the following statement

UPDATE overtime SET osalary=osalary+total where overtime.eid=something

here 'total' is the amount to be incremented.but this statement is not working.please help

webfred
Master Smack Fu Yak Hacker

8781 Posts

Posted - 2012-01-17 : 06:01:29
'total' is coming from where?


No, you're never too old to Yak'n'Roll if you're too young to die.
Go to Top of Page

lamiajoyee
Starting Member

15 Posts

Posted - 2012-01-17 : 06:47:44
'total' is an integer.it is coming from c#
Go to Top of Page

webfred
Master Smack Fu Yak Hacker

8781 Posts

Posted - 2012-01-17 : 07:04:57
Maybe you can show us a bit more on what you are really doing/coding because the shown example above should work.
And maybe you can make more clear the meaning of "is not working" - any errors or what?


No, you're never too old to Yak'n'Roll if you're too young to die.
Go to Top of Page
   

- Advertisement -