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

Crystal Reports 10 - Query Engine Error 21000

Status
Not open for further replies.

SQLLady

MIS
Jun 20, 2002
69
US
I am using Crystal Reports version 10. I am getting the following error message: >> There was an error retrieving data from the server: Query Engine Error: '21000(Microsoft ODBC SQL SERVER Driver...subquery returned more than 1 value)<<<
has anyone had this problem and if so can you tell me how to fix it? thanks in advance.
 
Chack the logic in your report - it appears that you have a formula ( or a selection criteria ) that uses somthing like
{SomeField} = ( some subquery)
and that subquery is returning multiple values - check the subquery ( by itself) to insure it returns only 1 value.



[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
Thanks. I am learning CR on the fly. Can you tell me how to run this query(not written by me) to troubleshoot the error? thanks again.
 
Depends on what your datasource is, if you have questions about data, please include where you are getting your data from (SQL Server, a table or a view or a stored procedure???).

You might copy the SQL from the Database->Show SQL Query and paste it into your SQL Query Analyzer if it was constructed by the Crystal interface, but I'd guess that you have an Add Command, or a stored procedure or joined views, in which case there's an error in the design or implementation.

The meaning of the error is that a comparison is being done where a field is supposed to equal some distinct value, but the returned comparison that it was to equal has more than one value returned.

-k
 
Oh, to look at the query if an Add Command was used, go to Database->Database Explorer (whatever it is in CR 10, I think it's the top choice).

Right click the data source and select View.

-k
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top