Link to home
Start Free TrialLog in
Avatar of ChadMarsh
ChadMarshFlag for United States of America

asked on

Query Engine Error

Hello Experts,
I am trying to run a Crystal report from a dataset and keep getting the following error.

Query Engine Error: 'C:\Documents and Settings\CHADMARSH\ASPNET\Local Settings\Temp\temp_3d99a711-7b0c-4196-bc93-b94d70aad41f.rpt'

The steps I have taken so far are:
1. Verified that the dataset is filling
2. Verified that the table in my xsd file exactly matches my report

I have done about everything I could find on the web including all the steps from the Crystal kbase
http://support.businessobjects.com/library/lbase/articles/c2011619.asp

The test report I created only has 3 columns in it from a MSSQL database.
Here is the code from my webform

Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        'Put user code to initialize the page here
        Dim report As New CrystalReport1
        Me.SqlDataAdapter1.Fill(Me.DsReports1, "de_users")
        report.SetDataSource(Me.DsReports1.Tables("de_users"))
        Me.CrystalReportViewer1.ReportSource = report
    End Sub
I would really appreciate any help
Thanks
Chad
Avatar of ChadMarsh
ChadMarsh
Flag of United States of America image

ASKER

Avatar of Mike McCracken
Mike McCracken

By exactly matching that includes field types and length?

mlmcc
My table has an int and 2 varchars.  The xsd file has the int and 2 strings which I assume is OK since varchar is not an option for in the xsd table.

                  SQL Database            XSD File
ID                        int 4                     int
first_name           varchar 50             string
last_name            varchar 50             string

Could it be the varchar's?
I think it could be.  The STRING is probably being treated as a MEMO field where as the varchar is a fixed length.

Can you use TEXT(50) or STRING(50) in the XSD file?

mlmcc
After I posted that, I created a new report with just the ID so both the database and the XSD file only had the
int.  It still gave the same error. Maybe I am doing something wrong in the process of creating.  I don't know if it will help or not, but here are the steps I am doing:
1. Drag a dataadapter to my web form and configure it for the table that I want.
2. Generate my dataset from the dataadapter. I usually go to preview data and fill it just to be sure it's bringing back records.
3. Add a Crystal report.  Select my datasource from Project Data/ADO.NET datasources.
4. Add the fields I want to my report.
5. In the on load event of my  web form add the following code:
        Me.SqlDataAdapter1.Fill(Me.DataSet11, "de_users")
        Dim rpt As New CrystalReport1
        rpt.SetDataSource(Me.DataSet11.Tables("de_users"))
        Me.CrystalReportViewer1.ReportSource = rpt
6. Then I have been right clicking and selecting preview in browser to see if it works.  That's when I get the error.
Maybe this will give a clue to if I am making a mistake somewhere else.
Thanks for the help.
Chad
ASKER CERTIFIED SOLUTION
Avatar of Mike McCracken
Mike McCracken

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thanks for all your help
Glad i could help

mlmcc