Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

RDC's SQLQueryString vs. RecordSelectionFormula

Status
Not open for further replies.

jedownsjr

IS-IT--Management
Jun 2, 2003
121
US
In the RDC, there are 2 properties belonging to the Report object -- SQLQueryString vs. RecordSelectionFormula. It seems like sometimes a report designed using Crystal Reports will store the record selection criteria in one, while another report will store the record selection criteria in the other. Is this due to Crystal syntax, complexity of the formula that the select expert can't interpret, evaluation time during the processing of the report or ??? I'm not sure when to use one property vs. the other.

Thanks for any help on this.
 
The SQLQueryString property is like going to Database > Show SQL Query in the CR Designer, while RecordSelectionFormula is the contents of the ... you guessed it, the Record Selection Formula.

If the report was designed with a Record Selection Formula (RSF), then the SQL was edited in the Show SQL Query (SSQ)window, the RSF won't necessarily reflect the contents of SSQ.

Here's a whitepaper about it:

-dave
 
Thanks for the info!

So is it correct to say that if you want to access the complete selection criteria, it may be more complex than the RecordSelectionFormula can handle and you should access it using the SQLQueryString? I am guessing that only 1 of the 2 properties will be used in the report, and that it tries to store it all in the RecordSelectionFormula if it can, but if it can't it stores it in the SQLQueryString? (My formula in this particular report was not edited in the SSQ window, but I edited it in from the Select Expert window by clicking on "Show Formula" -- not sure why it has selected to store the value in the SQLQueryString formula since I started out using the Select Expert unless it just got so complex Crystal didn't know what to do with it in the Select Expert (or RecordSelectionFormula) any longer and moved it to the SQLQueryString where it can handle it...? Am I assuming too much? That's the only way I can reason through it. The reason it is important to me is that I want to know when to access which property.

Thanks again.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top