ACC1x: Error Using SQL in Report RecordSource Property

ID: Q93293


The information in this article applies to:


SYMPTOMS

You receive the following error message when you try to use a valid SQL statement as the RecordSource in a report:

This report is bound to a table or query that doesn't exist: '<SQL statement>'.


RESOLUTION

Create a query using the SQL statement, and then base your report on that query.


STATUS

Microsoft has confirmed this to be a problem in Microsoft Access versions 1.0 and 1.1. This problem no longer occurs in Microsoft Access version 2.0.


MORE INFORMATION

Steps to Reproduce Problem


  1. Open the sample database NWIND.MDB.


  2. Open the Category List query in Design view.


  3. From the View menu, choose SQL.


  4. Select the contents of the SQL window. Then, choose Copy from the Edit menu.


  5. Choose Cancel to close the SQL dialog box. Then close the Category List query.


  6. Open a new unbound form, and paste the SQL statement into the form's RecordSource property by choosing Paste from the Edit menu.


  7. View the form in Form view.


  8. Open a new unbound report, and paste the SQL statement into the report's RecordSource property by choose Paste from the Edit menu.


  9. Preview the report.


Note that you do not receive an error message in step 7, but you do in step 9. You can use a valid SQL statement as the RecordSource in a form, but not in a report.


Keywords          : kberrmsg kbusage RptProp 
Version           : 1.0 1.1
Platform          : WINDOWS 
Issue type        : kbbug 

Last Reviewed: March 12, 1999