Viewing 15 posts - 5,581 through 5,595 (of 7,484 total)
forsqlserver (8/24/2011)
But I am asking about the if else condition:
Suppose in one row at one time one startdate is coming but other termination date and officiatingstartdate is...
August 24, 2011 at 8:26 am
forsqlserver (8/24/2011)
Use HRMS
Go
Create TRIGGER SteagingAfterInserttest ON [dbo].[staging]
FOR INSERT,UPDATE
AS
Update Staging set Startdate=Startdate+'T00:00:00.000' where EmpId in (Select EmpId from inserted);
Update Staging set Terminationdate=Terminationdate+'T00:00:00.000' where EmpId...
August 24, 2011 at 7:38 am
Good question.
Isn't the inability to apply the loop hint to a right join a bit bizarre though? Although it seems pretty obvious why this happens, there is in fact...
August 24, 2011 at 3:47 am
forsqlserver (8/23/2011)
Tom I have a confusion here,Here we have FOR INSERT in trigger statement that means it will run on insert command only.
How will it run for update?
Instead of
create...
August 24, 2011 at 3:24 am
Could it be that people are trying to use sys.sp_ms_marksystemobject in a later version of SQL Server than the one it worked in? That would account for its not working...
August 24, 2011 at 3:17 am
Fal (8/23/2011)
ALZDBA (8/23/2011)
Well, if you put a tennis-ball as cover of the towbar of the Lada doesn't it at least starts looking like a sports car ? :hehe:
Er, do sports...
August 23, 2011 at 12:16 pm
forsqlserver (8/23/2011)
The same I have to done for update query can I use single trigger for both purpose...
Yes, same trigger will work for both update and insert provided you include...
August 23, 2011 at 12:12 pm
forsqlserver (8/23/2011)
Hi all,Some how I have created this below trigger
It's better to write a trigger that doesn't declare local varaibles, just in case at some time in the future...
August 23, 2011 at 4:51 am
Good question, but:
Although the later BoL versions (SQL 2005, 2008,2008 R2, and Denali) are better, and make it clear that they are talking about the names of system stored procedures...
August 23, 2011 at 3:36 am
Sarah Orange (8/22/2011)
August 22, 2011 at 5:47 pm
ChrisM@Work (8/22/2011)
August 22, 2011 at 6:28 am
Have you tried switching to use "using this security context" and specify the domain and group?
August 22, 2011 at 5:51 am
A nice easy one for Monday morning.
I was somewhat surprised to see it before 0100 BST on Sunday, though.
EDIT: Why are there two of this? Is it a consequence...
August 20, 2011 at 7:05 pm
A nice easy one for Monday morning.
I was somewhat surprised to see it before 0100 BST on Sunday, though.
August 20, 2011 at 7:03 pm
Eugene Elutin (8/20/2011)
I'm lucky same...
August 20, 2011 at 6:51 pm
Viewing 15 posts - 5,581 through 5,595 (of 7,484 total)