ignite-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Anil <anilk...@gmail.com>
Subject Re: IN Query
Date Fri, 28 Oct 2016 03:57:23 GMT
Hi Val,

the below one is multiple IN queries with AND but not OR. correct ?

SqlQiuery with join table worked for IN Query and the following prepared
statement is not working.

List<String> inParameter = new ArrayList<>();
inParameter.add("8446ddce-5b40-11e6-85f9-005056a90879");
inParameter.add("f5822409-5b40-11e6-ae7c-005056a91276");
inParameter.add("9f445a19-5b40-11e6-ab1a-005056a95c7a");
inParameter.add("fd12c96f-5b40-11e6-83f6-005056a947e8");
PreparedStatement statement = conn.prepareStatement("SELECT  p.name FROM
Person p join table(joinId VARCHAR(25) = ?) k on p.id = k.joinId");
statement.setObject(1, inParameter.toArray());
ResultSet rs = statement.executeQuery();

Thanks for your help.


On 28 October 2016 at 01:18, vkulichenko <valentin.kulichenko@gmail.com>
wrote:

> Hi,
>
> You can join multiple virtual tables in the same way:
>
> select p.name from Person p
> join table(id bigint = ?) i on p.id = i.id
> join table(name bigint = ?) j on p.name = j.name
>
> -Val
>
>
>
> --
> View this message in context: http://apache-ignite-users.
> 70518.x6.nabble.com/IN-Query-tp8551p8562.html
> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>

Mime
View raw message