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

Ask Your Question

read and change behave differently with the same SQLQuery


I'm using Gigaspaces 12.2.1.

I am storing space document made up of a property called id that is set as the spaceId (autogenerated == true) and various other properties that are of type String. Some indexed and some not.

The problem I am encountering is that if I create the following SQLQuery:

SQLQuery<MyDocument> sq = new SQLQuery<>("MyDocument","`id` IN (?) AND `prop1` IN (?) AND `prop2` IN (?)");
sq.setParameter(1, Lists.newArrayList("myId"));
sq.setParameter(2, Lists.newArrayList("value1"));
sq.setParameter(3, Lists.newArrayList("value6", "value7"));

and then populate the space with a MyDocument object which only matches id but not the other two properties, the read and change behavior are different.

I get zero entries when issuing a read call with the above SQLQuery object which is expected. But if I issue a change call with the same SQLQuery object the result is one changed entry which is not expected.

If I remove the id IN (?) from the query, change and read work as expected.

It seems like including the id property in the query causes other the properties to be ignored. I have also tried using id = ? with the appropriate setParameter and the other two IN clauses but the behavior does not change.

Am I missing something here? Is the query I'm trying to write valid? Any thoughts?



asked 2018-07-27 16:13:04 -0500

rowinggoon's avatar
edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted

This appears to be a bug. I have logged a ticket for this. If you would like to be notified on updates to this issue, please open a support case.

answered 2018-07-31 11:36:04 -0500

Dixson Huie's avatar
edit flag offensive delete link more

Hi, This issue is solved for our next release 14.2 version.

Regards, Ester.

answered 2019-02-28 03:11:53 -0500

Ester's avatar
edit flag offensive delete link more

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: 2018-07-27 16:13:04 -0500

Seen: 605 times

Last updated: Feb 28 '19