Re: Who may create a trigger on SYSOBJECTS table

From: David Portas (REMOVE_BEFORE_REPLYING_dportas_at_acm.org)
Date: 06/21/04


Date: Mon, 21 Jun 2004 16:33:00 +0100


>From Books Online:

"A trigger cannot be created on a temporary or system table, although
triggers can reference temporary tables. System tables should not be
referenced; use the Information Schema Views instead."

If you want to log creation of objects you could create a Job that regularly
polled the Info Schema views at suitable intervals. Alternatively, if this
is intended as a method of configuration management, you can use various
third-party tools to compare two database schemas and retrospectively
identify any changes that have been made.

-- 
David Portas
SQL Server MVP
--


Relevant Pages

  • Re: trigger is firing in wrong schema
    ... trigger has the same name in both schemas. ... The only difference is schema name ... I am sure this is an "oracle ... Can you reproduce ...
    (comp.databases.oracle.server)
  • Re: Unable to get the sql command in Audit table
    ... The output should be sent to an audit table in which it should ... and a trigger. ... oper ddl_log.operation%TYPE; ... Schema level doesn't trap anyone touching a named schema ... ...
    (comp.databases.oracle.server)
  • Re: Triggers seem to be compiled only randomly
    ... in the first script I had to insert the schema before the table name and the second worked fine without changes. ... All things are similar to equal, the only difference are the detail table and of course the trigger name, but in the first script I had to insert schema, the second works without. ... cIDVerarb =:OLD.cID; ...
    (comp.databases.oracle.misc)
  • Triggers seem to be compiled only randomly
    ... in the first script I had to insert the schema before the table name and the second worked fine without changes. ... All things are similar to equal, the only difference are the detail table and of course the trigger name, but in the first script I had to insert schema, the second works without. ... cIDVerarb =:OLD.cID; ...
    (comp.databases.oracle.misc)
  • Re: Record level security?
    ... the trigger is not sensing the delete action and it is allowing it to ... as prefixes; using the table names as prefixes causes code clutter. ... Erland Sommarskog, SQL Server MVP, esquel@xxxxxxxxxxxxx ... Books Online for SQL Server 2005 at ...
    (microsoft.public.sqlserver.security)

Loading