title: How to identify a query that returns a result set in Teradata?
body: <p>I am writing some simple program that parses queries into two buckets: </p>
  
  <p>1) those who do not have a result set (like INSERT, UPDATE, CREATE) </p>
  
  <p>2) and those who do (like SELECT)  </p>
  
  <p>As far as I understand, as long   as a query starts with <code>SEL</code> or <code>WITH</code> substrings it ALWAYS has a result set. Is this correct ? I am sure about <code>SEL</code>, but not quite sure about <code>WITH</code>. Is it possible that a query starts with <code>WITH</code> and does not have a result set ?  </p>