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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Select Expert and Show SQL Query

Status
Not open for further replies.

cc5305

MIS
Oct 4, 2000
70
US
Are the Select Expert tool and the Show SQL Query related in Crystal report? I just made some changes in the SQL Query, but all the Select Expert options that I have are gone now. I changed the SQL Query because the report wasn't linking the tables even though I linked the two tables together in the Visual Linking.
 
They do have some linkage - not enough to be useful, but enough to be irritating.
The Visual Linker will write simple joins in SQL, and display these in the Show SQL Query. If you start editing the SQL Query manually, then SCR realizes it should stop trying to further change the query from the Visual Linker, so the Visual Linker is basically useless at this point - it doesn't reflect changes made to the SQL Query manually, and the SQL Query doesn't reflect subsequent changes made in the Visual Linker, with the exception that if a new table is added, and fields from that table are added to the report, then the SQL Query will show these in the SELECT statement. However, the new table will not be joined until you do that manually in either the FROM or WHERE clauses.

A similar logic applies to the Record Select Experts - once you start editing the SQL statement manually, SCR realizes it needs to stop playing with the WHERE clause (which is what the record selection attempts to do).

The best way around this is to put off manually editing the SQL statement until you have all the tables joined in, and all the record selection formulas done. It doesn't eliminate the problem, but it minimizes the impact it has on your productivity.
 
Thanks, that definitely clarify a lot of my questions. But I find that if I force the Record Select Expert selections back into the Record Select Expert and the SQL Query, they will stay there for good (at least it seems like it so far).
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top