Skip Menu |

This queue is for tickets about the SQL-Interp CPAN distribution.

Report information
The Basics
Id: 39778
Status: open
Priority: 0/
Queue: SQL-Interp

People
Owner: Nobody in particular
Requestors: MARKSTOS [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Wishlist
Broken in: 1.06
Fixed in: 1.06



Subject: wish: optimize IN() to be ANY() for compatible PostgreSQL versions.
When using "IN()" multiple times with variable lengths of the list, a prepared statement is made for each length of the list, creating extra overhead. On compatible PostgreSQL versions, we can avoid this overhead by using this, which means the same thing: ANY (ARRAY[1,2,3,4]) The difference is that you can paramterize like this: ANY (?) So that you can only get one prepared statement for each length of the IN clause. The "wish" is that for compatible PostgreSQL versions, we will rewrite "IN()" clauses to use "ANY". Or perhaps alternately, we could explicity support ANY(), and handle creating the "ARRAY[]" constructor for the users.