Need a unique gift idea?
A Pastebin account makes a great Christmas gift
SHARE
TWEET

Untitled

a guest Dec 6th, 2018 68 Never
Upgrade to PRO!
ENDING IN00days00hours00mins00secs
 
  1. DECLARE @role varchar(20)
  2.    select @role = u.[role] from inserted i join users u on u.id = i.creator_id
  3.  
  4.    if @role = 'client'
  5.           update TableA
  6.           set updated_date = i.created_date from inserted i where TableA.id = i.trans_id
  7.  
  8.    if @role = 'tech'
  9.           update ticket
  10.           set updated_date = i.created_date from inserted i where TableA.id = i.trans_id and i.[public] = 'true'
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top