title: Error: 'ORA-24374: define not done before fetch or execute and fetch' when refreshing a report in Crystal Reports
body: <p>Using<br>
  Crystal Reports 2013<br>
  Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production</p>
  
  <pre><code>Failed to retrieve data from the database.
  Details: HY000: [Oracle][Ora]ORA-24374: define not done before fetch or execute and fetch
  </code></pre>
  
  <p>I have no comments (multi-line or single line), so <a href="https://apps.support.sap.com/sap/support/knowledge/public/en/2322011" rel="nofollow noreferrer">https://apps.support.sap.com/sap/support/knowledge/public/en/2322011</a> doesn't apply.</p>
  
  <p>The query works fine in DbVisualizer.</p>
  
  <p>I'm trying to combine two reports.  Records from the summary report should be in the group footer of the detail report.  (Yes, my first thought was to use a subreport and call it a day.  When I determined the report would take all week to run, I decided to have the database server do all of the work.)</p>
  
  <p>My query is 384 lines long, uses 16 parameters, and has no comments.  It is a join of two main queries.  I have tried using subqueries and common table expressions.  As expected, same results both ways.  All of the parameters used in the query are in the Parameter List in the Modify Command window in Crystal Reports.  I have looked through every parameter definition in the Parameter List and they all look good.</p>
  
  <p>When I have seen this error message before, I was able to delete comments and move forward.  This is different.</p>
  
  <p>Any idea what Crystal Reports is doing here?</p>