Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Inserted table
Message
From
26/02/2002 08:35:04
 
 
General information
Forum:
Microsoft SQL Server
Category:
Stored procedures, Triggers, UDFs
Title:
Miscellaneous
Thread ID:
00624840
Message ID:
00625024
Views:
12
If this is the whole trigger, I see no reason to involve a cursor.
CREATE TRIGGER trUpdateAnalVerification ON
[ERA_IL_Study_Analytes_Verification]
FOR UPDATE AS

DECLARE @rc int
SET @rc = @@ROWCOUNT

/*See if any rows were opened*/
INSERT INTO gerrystest 
VALUES (
 CAST(GETDATE() AS varchar(25)) + ', after open, ' + CAST(@rc as char(5)))
Also, a SQL Server trigger fires once for each data operation, no matter how many rows are modified. Change 1 row, the trigger fires once, 5 rows, the trigger fires once, zero rows - fires once.

-Mike
Michael Levy
MCSD, MCDBA
ma_levy@hotmail.com
Previous
Reply
Map
View

Click here to load this message in the networking platform