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

using data environment as a data source of report

Status
Not open for further replies.

ayeneww

Programmer
Dec 17, 2004
2
ET
I am using crystal report 8.0, access2000 database and visual basic 6.0.

my problem is:

I want to create a report using report expert wizard and the data source as data environment. But after I see the sql string of the Data environment in select record dialog I face a problem.
The sql string is this:

SHAPE {SELECT ID, Name + ' ' + FName + ' ' + GFName AS Name,
Birth_Date, starting_date
FROM Resident} AS Resident APPEND ({SELECT * FROM Dependant} AS Dependant RELATE 'ID' TO 'ID') AS Dependant


when i click ok it brings the following message microsoft

JET database engine:
Invalid SQL Statement; expected 'DELETE','INSERT','PROCEDURE','SELECT','UPDATE'

could you help me please
 
Dave!
Thanks for your replay and the references you suggest. I read the documents and it is valuable information but It does not address specifically my question.

Actually, setting Data environment is not a problem when there is no the so called "shape' which is useful to access data'hierarchically'. In other words, I want to display information from two tables which are related and have one- to- many relationship. I appriciate if there is also any other means of doing it without Data environment.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top