Error connecting Report to database via Data Environment 
Author Message
 Error connecting Report to database via Data Environment

I'm getting a "Syntax Error in FROM Clause" error, but
I'm starting to think maybe it isn't my SQL string that's
the problem.

I'm trying to report data from an SQL string. I created
a Data Environment with a connection that uses MS Access
as a datasource. I created a control based on some tables,
used it to put fields on the report, then deleted the
DataSource and DataMember properties of the report so
I can set these values at run time.

My Data Environment is 'deClientReport', command is  "Data',
report is 'rptClientReport', source table in the database is
'tblData'. My user invokes the following code with a command
button on a form:

 deClientReport.Commands("Data").CommandText =  _
    "SELECT Comments FROM tblData"

  Set rptClientReport.DataSource =  _
    deClientReport.Commands("Data").Execute

This is giving me the "Syntax Error in FROM Clause" error no
matter what I use for the SQL string. Is the error really my
SQL syntax (even the simple statement, above), or can anybody
see a problem with the way I'm trying to access the table?

Thanks for any feedback -

AS

-----= Posted via Newsfeeds.Com, Uncensored Usenet News =-----
http://www.*-*-*.com/ - The #1 Newsgroup Service in the World!
-----==  Over 80,000 Newsgroups - 16 Different Servers! =-----



Mon, 24 Nov 2003 02:29:58 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. Error connecting Report to database via Data Environment

2. Data Environment / Data Report / Changing database file at run time

3. Adding a Database to an existing Report (from a Data Environment)

4. Error opening data-environment report on 2nd try.

5. Access 2 to Oracle database via ODBC reports error -7751

6. Data Environment / Data Report Problem

7. Showing parameters pass to data environment in data report header

8. Help! Data Report without Data Environment

9. data report / data environment designers

10. VB6 Data Environment & Data Report

11. Problem with Data Environment and Data Report

12. help - data environment and data reports

 

 
Powered by phpBB® Forum Software