Skip to Content
0
Aug 27, 2009 at 03:25 PM

Retrieve SQL Query from report without RAS.

43 Views

We have a fat client application which uses Crystal Reports. We upgraded from the RDC/ActiveX viewer to the .Net SDK/.Net Viewer. One feature that we miss is that we used to read the SQL Query that a report used and wrote it to our log file. This helped with debugging and with troubleshooting problems in the field.

Since we only deploy the freely distributable Crystal Reports model and I don't think that RAS falls into this category is there a way which we can read the SQL Query from a report? If not, could you add this to a list of requested features for future versions.

I understand why you removed the ability to set the SQL query, but simply reading it does add value. Maybe it is difficult for you to return this before the report is run in which case giving us the ability to read the value after the report has been run would also be fine.

Alternatively some sort of event that is fired each time a query is executed would also be helpful as this would allow Crystal Reports clients to monitor SQL from sub-reports. You could even build a robust logging mechanism which could report additional information (i.e. number of rows returned, formula evaluations, or anything related to report execution). All of this would make troubleshooting report issues easier for those of us who use Crystal Reports.