title: Include Where statement on SQL Trigger
body: <p>I am quite new to writing SQL triggers and I had one working for a while now as desired however now I would like to add a where clause to the trigger so that it only fires if a certain condition is met.</p>
  
  <p>In this particular scenario I want to check and see if <code>ContextDN like '%FA 2012%'</code> and if so then have the trigger fire. Here is my current trigger:</p>
  
  <pre><code>CREATE TRIGGER [dbo].[setAsMoodle]
  ON [dbo].[LMS_Section]
  For Insert
  As
  INSERT INTO [dbo].[CUS_LmsSection_LmsProxy] (LMSSectionID, LMSProxyID, LMSSectionCtxDN)
  select  SectionID , 'DEE76E47-25E6-459B-9D38-1BCAFA44077A', ContextDN from inserted
  </code></pre>
  
  <p>Any suggestions on how to go about doing this?</p>