Subject Re: [firebird-support] Perl, Firebird, and empty Where clause
Author Nick Upson
On 19 July 2012 23:23, Paul Vinkenoog <paul@...> wrote:

> **
>
>
> Hello Daniel,
>
>
>
> > I'm trying to have an existing perl program, that is using the DBI
> > system for theoretical database interoperability, to use Firebird. I've
> > discovered that, as a standard, this program executes statements such as,
> >
> > select * from table where pkey=''
> >
>
> > Without changing the perl script, is there a way I can have Firebird
> > actually return the table using the above SQL?
>
> No. You would have to intercept the SQL at some point and change it. If
> you want the whole table, leave out the WHERE clause and if that isn't
> possible, use a tautology, e.g. "...where 1=1" (or append " or 1=1" to the
> existing clause).
>
> Good luck,
> Paul Vinkenoog
>
>
>

you could replace the table with a selectable stored proc that has pkey as
an input param, then have the proc return whatever you want


[Non-text portions of this message have been removed]