Subject Re: Sets in like operator
Author marc_guillot
--- In firebird-support@yahoogroups.com, Helen Borrie <helebor@...> wrote:
> I guess by this statement that you want to write
> a query for your application that can take an
> arbitrary set of characters as a single
> parameter. That is not currently available in DSQL.
>
> You could write a stored procedure that takes a list of values as
input, e.g.
>
> create procedure retrieve_from_list(input_list varchar(70)
> returns (<.....>)
> as
> ...
>
> Your PSQL code breaks down the list internally in
> a WHILE loop, picking out each value, one by one,
> into a local variable. An embedded
> FOR...SELECT...INTO loop takes the latest value
> of the variable as the parameter for a 'starting
> with :aVariable' clause in the SELECT specification.
>
> You would have to take care that the list
> argument was defined to be long enough to
> accommodate the longest possible list.
>
> ./heLen

Thanks Helen, your guess is right.

I will look try using a stored procedure like you say.