Welcome to the new Gigaspaces XAP forum. To recover your account, please follow these instructions.

Ask Your Question

.Net SpaceIterator with SQL Query and IN operator


I'm using the .Net api of gigaspace, and I've got an issue using the the spaceIterator with an SQL query:

h5. string queryString = "select * from myPojo where id IN ('0', '1')"; h5. MyPojo template = new MyPojo(); h5. SqlQuery<mypojo> q = new SqlQuery<mypojo>(template, queryString); h5. ISpaceIterator<mypojo> it = spaceProxy.GetSpaceIterator<mypojo>(q, IteratorScope.ExistingAndFutureEntries, bufferSize, -1);

Here I get the error message :

java.sql.SQLException: Operation doesn't support complex SQL queries

When I'm using the same query with a ReadMultiple method, it simply works. I didn't see any documentation about that limitation.

Have someone an idea about what's going on here? Is this really a limitation of the .Net API. I think that it's working with the java API.

Best regards,

{quote}This thread was imported from the previous forum. For your reference, the original is [available here|http://forum.openspaces.org/thread.jspa?threadID=2788]{quote}

asked 2009-01-05 08:54:42 -0500

updated 2013-08-08 09:52:00 -0500

jaissefsfex gravatar image
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

This is not supported also with the Java API. The problem is the notification registration used as part of the Iterator creation that does not support OR based queries. AND based queries will be supported.
If your query result set involve less than 10,000-20,000 objects , 1K size over LAN - you can safely use the readMultiple.
7.0 might support this when using the new GSIteratorConfig when iterating over existing objects.

answered 2009-01-05 09:14:53 -0500

shay hassidim gravatar image
edit flag offensive delete link more


Hi Shay,

Thanks for your answer.

I would also like to know if the remote executor API (Task, RemoteExecutor) exists in the .Net API.
I've seen it in the Java API, but it seems to be not available in .Net.
Am I right?

wolf651 gravatar imagewolf651 ( 2009-01-05 10:04:40 -0500 )edit

.Net API scheduled to support executors with XAP 7.0. Still, you can mimic its behavior using the polling container and a write of a "command object" that will trigger the polling container with the appropriate business logic. Shay

shay hassidim gravatar imageshay hassidim ( 2009-01-05 11:33:49 -0500 )edit

It is currently planned for 7.0.

nirpaz gravatar imagenirpaz ( 2009-01-05 11:38:49 -0500 )edit

Thanks for your suggestion.

wolf651 gravatar imagewolf651 ( 2009-01-05 12:30:07 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2009-01-05 08:54:42 -0500

Seen: 51 times

Last updated: Jan 05 '09