There is a trigger defined for INSERT operations on a
table, in an OLTP system. The trigger is written to
instantiate a COM object and pass the newly insterted rows
to it for some custom processing. What do you think of this
implementation? Can this be implemented better?
Answer Posted / swapna
Instantiating COM objects is a time consuming process and
since you are doing it from within a trigger, it slows down
the data insertion process. Same is the case with sending
emails from triggers.
This scenario can be better implemented by logging all the
necessary data into a separate table, and have a job which
periodically checks this table and does the needful.
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
You schedule a job to run every minute what will happen if the first job runs more than 1 min? Will the second instance of the job start?
After creating the cube, if we added a new column to the oltp table then how you add this new attribute to the cube? : sql server analysis services, ssas
How can we delete Duplicate row in table?
Does any body please help me what question's have asked for SSRS in the interview?
Which is faster statement or preparedstatement?
Is BCNF better than 2NF & 3NF? Why?
List out the differences between global and local temp tables in sql server?
What is the difference between char and varchar2 datatype in sql?
What is the difference between row_number and dense_rank?
How to add additional conditions in SQL?
What is sql server replication? : sql server replication
How to recompile stored procedure at run time?
How to get the definition of a user defined function back?
What guidelines should be followed to help minimize deadlocks?
What are the two modes of authentication in sql server?