Home Forums SQL Server 2008 T-SQL (SS2K8) Trigger To Prevent a User From Inserting a Blank Column RE: Trigger To Prevent a User From Inserting a Blank Column

  • Your trigger is checking the entire table, not the rows just inserted. So if there's any blank values anywhere in the table, the trigger will fail. You probably want to use the inserted table in the exists, rather than the actual table name.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass