title: SQL Error: The executeQuery method must return a result set
body: <p>while trying to execute the below query in SQL server I am getting an error SQL Error: The executeQuery method must return a result set.</p>
  
  <pre><code>with cte 
  AS
  (
      SELECT GUID,seq original_seq_no, ROW_NUMBER()
      OVER ( PARTITION BY GUID ORDER BY seq) AS new_seq_no
      FROM CHK_SEQ
  )
  
  update  CHK_SEQ
  set     CHK_SEQ.seq = r.new_seq_no
  from    cte r
  where CHK_SEQ.seq = r.original_seq_no AND CHK_SEQ.GUID= r.GUID;
  </code></pre>
  
  <p>can any one please help me with this.</p>