Free for PREMIUM members
ALTER TABLE APSupplier
ALTER COLUMN OnHold SET DEFAULT 'Y'
Open in new window
CREATE TRIGGER after_insert_table1 ON yourtable
set t.OnHold = 'Y'
FROM yourtable t
WHERE t.PK in ( SELECT i.PK FROM INSERTED )
and ( t.OnHold IS NULL OR t.OnHold <> 'Y' )
Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.