Subject Re: [firebird-support] PSQL Query - Am I doing this right?
Author Ann W. Harrison
myles@... wrote:
> I have a stored procedure that I wish to pass in a variable (varchar(200))
> that contains the name of a field to use in a query, along with the search
> value to search (varchar(200) also).
>
> In trying to construct the query in the stored procedure, my WHERE clause
> looks like this:
>
> WHERE (ASSET.RECORD_INACTIVE <> 'Y') and (:V_SEARCH_FIELD LIKE
> ASCII_CHAR(39) || :A_FOR || ASCII_CHAR(39))
>

Look at the description of execute statement in the release notes.
It lets you build a statement on the fly.


Regards


Ann