Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Multi Row Subquery in Where Clause Post Reply Post New Topic
Author Message
dmurray9133
Newbie
Newbie


Joined: 25 Oct 2011
Online Status: Offline
Posts: 1
Quote dmurray9133 Replybullet Topic: Multi Row Subquery in Where Clause
     Posted: 25 Oct 2011 at 5:17pm

Is there a way around this without writing everything in a command SQL or a Correlated subquery??

I wish to qualify my main query by setting a column to either be IN or NOT IN to a Subquery. The Subquery returns muliple rows. Here is my SQL Express named "MULTI":
 
(SELECT  ApplApplicants.ApplicationID FROM ApplAddOns)
 
The minute I do this i get an error message: "Subquery returned more than 1 value. this is not permitted....when subquery follows =, >, >=, <, <=...."
 
Fine...I don;t plan to set my qualifer to =. I am using either NOT IN or IN..
 
Here is my SELECT Expert condition: not ({ApplApplicants.ApplicationID} in [{%MULTI}])
 
I get the same error above....I can do what I need in straight SQL or use a correlated subquery and then filter the records...but I am a teacher and my students are not good with SQL so I would like to avoid that...
 
Why won't Crystal let you set a condition on a column to a multi-row subquery??
 
Thanks
 
 
IP IP Logged
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum