On 14/12/2019 06:13, Hugo Larson hugo.lar...@yahoo.com 
[firebird-support] wrote:
> Is it possible to use wildcard somehow like this.
> 
> SELECT * FROM PRODUCT
> WHERE PRODUCT.ID IN (:param)
> 
> param will be a list or IDs or a wildcard.
> % does not work.
> Goal is to get all PRODUCT with wildcard :param

Neither will work. `IN` doesn't take wildcards, and if you want to use a 
list of values, you need to have individual parameters for each value in 
the list (although some frameworks will allow you to define single 
parameter and the framework will expand it to the right number of 
parameters at execution time).

If you want to use wildcards, you need to use LIKE (or SIMILAR TO). 
Using SIMILAR TO you could simulate a list of values by separating them 
with pipes (|).

Mark
-- 
Mark Rotteveel
  • [firebird-support] ... Hugo Larson hugo.lar...@yahoo.com [firebird-support]
    • Re: [firebird-... Mark Rotteveel m...@lawinegevaar.nl [firebird-support]

Reply via email to