JDBC Input - parameter with multiple values

Hello,

I have a SQL Server query that that has one parameter with one or more values. In raw SQL it looks like this:

select top 1 * from a
inner join b on b.ID=a.ID and b.Resp in (1, 2)

So Logstash statement looks like this:

select top 1 * from a
inner join b on b.ID=a.ID and b.Resp in (:resp_param)

resp_param can have one, two or even more values, depending on what we specify as a parameter in JDBC input. When it's single value then there's no issues, I just use this setting:

parameters => { "resp_param" => "1"}

What about multiple values? I tried different combinations but no luck so far. Is it possible for int and varchar fields at all?
Thanks.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.