| |
GeekInterview.com > Interview Questions > Database > SQL Server
| Print | |
Question: Can we generate a trigger for two tables? if so what is the query to generate a trigger for two tables employee table and department table with employee having department no.
|
| July 07, 2006 03:31:54 |
#2 |
| usha |
Member Since: Visitor Total Comments: N/A |
can we generate a trigger for two tables? if so wh... |
Yes, we can generate. I am giving u one example CREATE TRIGGER trg_SampleINSERT ON dbo.SampleMainTable FOR INSERT AS INSERT INTO temp_SampleTable SELECT * FROM INSERTED |
| |
Back To Question | |