title: SQL Server : Invalid cursor state (0) state why?
body: <p>I have a table on which there is update trigger written it has print statement before go statement. </p>
  
  <pre>
  ALTER TRIGGER user_type_check ON user_table
      --code
  
      PRINT 'Modification of user is done.'
  GO
  SET QUOTED_IDENTIFIER OFF 
  GO
  SET ANSI_NULLS ON 
  GO
  
  
  </pre>
  
  <p>Now with this structure whenever i perform update operation on the table it failed. </p>
  
  <p>However when i moved the PRINT statement after the go statement in the trigger its working fine without error. Why is such a behavior ?</p>