ignite-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrey Mashenkov <andrey.mashen...@gmail.com>
Subject Re: sql query in case of cluster group
Date Mon, 17 Jul 2017 10:24:22 GMT
1. LIMIT make no sense without ORDER for non-local queries and when
sqlQueryParallelizm > 1.
As in that case, data from different index segments will be merged out of
order and you can get different results with same query from run to run .

2. You use ClusterGroup to make your jobs to be run on certain nodes, but
it doesn't affect operations inside a job.
So, non-local sql query will be run on all data nodes.

On Mon, Jul 17, 2017 at 12:44 PM, neerajbhatt <neerajbhatt2000@gmail.com>
wrote:

> Hi Andrew
>
> It seems to be an order by issue. We have created a test project in github
> https://github.com/neerajbhatt/testIgnite
>
> If we use PutItems to put some records in a partitioned cache(TESTCACHE)
> args[0]=number of records, and then Get the items by
> GetItemsWithClusterGroup args[0] = query type (0 or 1), args[1]= number of
> queries and args [3] as last digit of ip.
>
> for first query ("SELECT T.id FROM " + "TESTCache.TestItem as T LIMIT 3")
> different ids are given for different cluster groups( each cluster group
> having one node)
>
> for second query ("SELECT T.id FROM " + "TESTCache.TestItem as T order by
> field1 desc LIMIT 3") we are getting same ids for each cluster group. It
> seems in case of order by instead of cluster group data is being fetched
> from whole cluster.
>
> Please suggest
>
>
>
> --
> View this message in context: http://apache-ignite-users.
> 70518.x6.nabble.com/sql-query-in-case-of-cluster-group-tp14884p14994.html
> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>



-- 
Best regards,
Andrey V. Mashenkov

Mime
View raw message