ignite-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Matt <dromitl...@gmail.com>
Subject SQL "= ANY (?)" supported?
Date Sun, 30 Apr 2017 07:54:33 GMT
Hello,

I'm trying to run a SQL standard query with a "WHERE foo = ANY(?)" but it
seems it's not supported by Ignite.

The code looks like this, it's fairly simple:

---






*String sql = "SELECT * FROM Foo WHERE foo = ANY(?)";String[] params =
{"aaa", "bbb"};SqlQuery<String, Foo> query = new SqlQuery<>(Foo.class,
sql);query.setArgs(params);cache.query(query);*
---

The error is "*IgniteSQLException: Failed to parse query*" and
"*JdbcSQLException:
Syntax error in SQL statement*" and it's caused by the "ANY(?)". I also
tried writing the query without the params, hardcoding the values directly
on the sql variable, but I'm getting the same result.

Is this kind of query supported? Any workaround to load a list of objects
dynamically (from an array) without writing multiple "foo = ? OR foo = ? OR
..." on the query?

Best,
Matt

Mime
View raw message