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
What is an expensive query?
Distinguish between commit and rollback?
What do you understand by check constraint in sql server?
What is dbcc?
What is analysis service repository?
What is difference between inner join and full join?
What is transact-sql ddl trigger?
What is difference between global temporary tables and local temporary tables?
Explain different types of self contained sub query?
Determine when an index is appropriate?
What is the purpose of linked server configuration in sql server?
What are the Advantages of using CTE in sql server?
List some of the rules that apply to creating and using a ‘view’
What is function of ROLLUP ?
How sql server enhances scalability of the database system?