You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by Sachin janani <sa...@gmail.com> on 2022/06/25 07:36:03 UTC

Sql Query to read data for a partition of a table

Hi Team,
Is it possible in ignite to query data for a specific partition in SQL
query. I have a requirement where i have to do colocated task by partition
using SQL query so just want to know is there any way in SQL query to
achieve this.


Thanks and Regards,
*Sachin Janani*

Re: Sql Query to read data for a partition of a table

Posted by Sachin janani <sa...@gmail.com>.
We have one proprietary application which queries different SQL engines
using JDBC and for some operations it has to scan data partition by
partition. So we want to achieve this for ignite via JDBC.Can we do set
partitions via JDBC or is there any way we can query data by partition  ?

On Sun, Jun 26, 2022 at 8:12 PM Pavel Tupitsyn <pt...@apache.org> wrote:

> > How can i do that using JDBC?
>
> Why would you want to do that, when we are already inside the Ignite
> Compute task?
> Ignite SQL API call will be a lot faster.
>
> On Sun, Jun 26, 2022 at 8:19 AM Sachin janani <sa...@gmail.com>
> wrote:
>
>> Thanks for a quick response. How can i do that using JDBC?
>>
>>
>> Thanks and Regards,
>> Sachin Janani
>>
>> On Sat, Jun 25, 2022 at 1:46 PM Pavel Tupitsyn <pt...@apache.org>
>> wrote:
>>
>>> SqlQuery#partitions does just that:
>>>
>>> https://ignite.apache.org/releases/latest/javadoc/org/apache/ignite/cache/query/SqlQuery.html#setPartitions-int...-
>>>
>>> On Sat, Jun 25, 2022 at 10:36 AM Sachin janani <
>>> sachin.janani203@gmail.com> wrote:
>>>
>>>> Hi Team,
>>>> Is it possible in ignite to query data for a specific partition in SQL
>>>> query. I have a requirement where i have to do colocated task by partition
>>>> using SQL query so just want to know is there any way in SQL query to
>>>> achieve this.
>>>>
>>>>
>>>> Thanks and Regards,
>>>> *Sachin Janani*
>>>>
>>>>
>>>
>>
>> --
>> *Sachin Janani*
>>
>>
>

-- 
*Sachin Janani*

Re: Sql Query to read data for a partition of a table

Posted by Pavel Tupitsyn <pt...@apache.org>.
> How can i do that using JDBC?

Why would you want to do that, when we are already inside the Ignite
Compute task?
Ignite SQL API call will be a lot faster.

On Sun, Jun 26, 2022 at 8:19 AM Sachin janani <sa...@gmail.com>
wrote:

> Thanks for a quick response. How can i do that using JDBC?
>
>
> Thanks and Regards,
> Sachin Janani
>
> On Sat, Jun 25, 2022 at 1:46 PM Pavel Tupitsyn <pt...@apache.org>
> wrote:
>
>> SqlQuery#partitions does just that:
>>
>> https://ignite.apache.org/releases/latest/javadoc/org/apache/ignite/cache/query/SqlQuery.html#setPartitions-int...-
>>
>> On Sat, Jun 25, 2022 at 10:36 AM Sachin janani <
>> sachin.janani203@gmail.com> wrote:
>>
>>> Hi Team,
>>> Is it possible in ignite to query data for a specific partition in SQL
>>> query. I have a requirement where i have to do colocated task by partition
>>> using SQL query so just want to know is there any way in SQL query to
>>> achieve this.
>>>
>>>
>>> Thanks and Regards,
>>> *Sachin Janani*
>>>
>>>
>>
>
> --
> *Sachin Janani*
>
>

Re: Sql Query to read data for a partition of a table

Posted by Sachin janani <sa...@gmail.com>.
Thanks for a quick response. How can i do that using JDBC?


Thanks and Regards,
Sachin Janani

On Sat, Jun 25, 2022 at 1:46 PM Pavel Tupitsyn <pt...@apache.org> wrote:

> SqlQuery#partitions does just that:
>
> https://ignite.apache.org/releases/latest/javadoc/org/apache/ignite/cache/query/SqlQuery.html#setPartitions-int...-
>
> On Sat, Jun 25, 2022 at 10:36 AM Sachin janani <sa...@gmail.com>
> wrote:
>
>> Hi Team,
>> Is it possible in ignite to query data for a specific partition in SQL
>> query. I have a requirement where i have to do colocated task by partition
>> using SQL query so just want to know is there any way in SQL query to
>> achieve this.
>>
>>
>> Thanks and Regards,
>> *Sachin Janani*
>>
>>
>

-- 
*Sachin Janani*

Re: Sql Query to read data for a partition of a table

Posted by Pavel Tupitsyn <pt...@apache.org>.
SqlQuery#partitions does just that:
https://ignite.apache.org/releases/latest/javadoc/org/apache/ignite/cache/query/SqlQuery.html#setPartitions-int...-

On Sat, Jun 25, 2022 at 10:36 AM Sachin janani <sa...@gmail.com>
wrote:

> Hi Team,
> Is it possible in ignite to query data for a specific partition in SQL
> query. I have a requirement where i have to do colocated task by partition
> using SQL query so just want to know is there any way in SQL query to
> achieve this.
>
>
> Thanks and Regards,
> *Sachin Janani*
>
>