Subject Re: [firebird-support] 1500 values in IN (...) clause fails
Author Thomas Steinmaurer
Kjell,

> I just bumped up ECO to select up to 1500 objects from persistence in
> one go, resulting in a select like this:
>
> SELECT "Uppgift_A"."ECO_ID",
> "Uppgift_A"."ECO_TYPE",
> "Uppgift_A"."Hållare"
> FROM "Uppgift" "Uppgift_A"
> WHERE "Uppgift_A"."Hållare" IN (601089, 601092, ...)
>
> I checked that it put exactly 1500 values in there, but FB fails:
>
> Message: isc_dsql_prepare failed
>
> SQL Message : -901
> Unsuccessful execution caused by system error that does not preclude
> successful execution of subsequent statements
>
> Engine Code : 335544569
> Engine Message :
> Dynamic SQL Error
> SQL error code = -901
> Implementation limit exceeded
> Too many values (more than 1500) in member list to match against
>
>
> So, either I've been misinformed or there's a bug in FB. Either FB
> should support 1500 and has a bug, limiting it to 1499. Or FB is
> supposed to support up to BUT NOT INCLUDING 1500 values, in which case
> every place I've seen this limit mentioned has been incorrect.
>
> So, which is it?
>
> Not that it matters very much, it just nags me that it seems wrong.

http://tracker.firebirdsql.org/browse/CORE-1438


--
With regards,

Thomas Steinmaurer
Upscene Productions
http://www.upscene.com
http://blog.upscene.com/thomas/

Download LogManager Series, FB TraceManager today!
Continuous Database Monitoring Solutions supporting
Firebird, InterBase, Advantage Database, MS SQL Server
and NexusDB!