Hi, What are you trying to achieve?
What is cache mode? For REPLICATED cache, your query will be sent to and executed on one random node. 1. You can sent a compute job [1] to certain node (via ignite.compute(ignite.cluster().forNode(...)).execute(task)) or affinity job [2] (ignite.compute().affinityRun()) which will execute local SQL query [3]. See compute docs [1] and SQL local flag docs [2]. 2. If cache is PARTITIONED, then you may want to send a query to node with certain partition. Then you can try to set partitions explicitly via SqlFielQuery.setPartitions(). [1] https://apacheignite.readme.io/docs/distributed-closures#call-and-run-methods [2] https://apacheignite.readme.io/docs/collocate-compute-and-data#affinity-call-and-run-methods [3] https://apacheignite-sql.readme.io/docs/local-queries On Tue, Jun 5, 2018 at 3:35 PM, Shravya Nethula < [email protected]> wrote: > Hi, > > I am trying to execute the following select query using the native java > client on a cluster of 2 nodes. > > String query = "select * from Person"; > List<List<?>> results = superCache.query(new > SqlFieldsQuery(query)).getAll(); > > Now, is any there way to execute the same query on only one specific remote > node? > > Can anyone please post some suggestions in this regard? > > Regards, > Shravya Nethula. > > > > > > > -- > Sent from: http://apache-ignite-users.70518.x6.nabble.com/ > -- Best regards, Andrey V. Mashenkov
