RE: Unusual query behaviour
Posted in 2004
I had a similar problem getting the same error, -284, when running a query
with a optimizer directive. The query would run fine without the directive.
Sent a test case to Informix and it is defect #165540.
Regards,
Bill
> -----Original Message-----
> From: kuppusab@nasd.com [SMTP:kuppusab@nasd.com]
> Sent: Wednesday, March 17, 2004 1:40 PM
> To: informix-list@iiug.org
> Subject: Unusual query behaviour
>
> Hi Gurus,
> The Environement : I use Informix 9.30 , 4gl 7.20UD2 on Solaris 2.6.
>
> Problem : The application has used a particular program for years but
> now it gives me a problem when it executes a certain query.
>
> The query : select 1 from table1
> where column1 = "ABC"
> and column2 = "XYZ"
>
> When I run the sql in dbaccess it gives me 1 as many as the number of
> rows it gets.
>
> However when I run the sql in 4gl , it 'now' says
> "SQL statement error number -284.
> A subquery has returned not exactly one row." if there are multiple
> rows.
>
> Is there any reason for this response ? The only thing that changed is
> the IDS version from 9.20 to 9.30. All compilers are the same.
>
> I did fix the problem by retrieving the count in a variable and using
> it further for validations.
>
> Curious to know.
>
> Thanks in Advance
> Bhaskar
sending to informix-list