You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by siva <si...@bizruntime.com> on 2021/01/21 14:37:51 UTC
SqlQuery Deprecated Since 2.8, please use SqlFieldsQuery
instead....How to get result as passing model Type with SqlFieldsQuery?
Hi,
I am using .net Ignite v2.9.1 and
Since SqlQuery deprecated in documentation suggesting please use
SqlFieldsQuery.
what is the way to get result as Type using sqlfieldsquery?
for example query
select * from mytesttable
Thanks.
--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
Re: SqlQuery Deprecated Since 2.8, please use SqlFieldsQuery
instead....How to get result as passing model Type with SqlFieldsQuery?
Posted by Ilya Kasnacheev <il...@gmail.com>.
Hello!
Why not:
SELECT t.*, t._val from materials t INNER JOIN ...
Regards,
--
Ilya Kasnacheev
чт, 21 янв. 2021 г. в 19:19, siva <si...@bizruntime.com>:
> Hi,
>
> It's working fine in "select _val from mytesttable" query but in case of
> sub
> query or joins it's failing with an error like column not found
>
> It's failing access column with and without table Aliases.
> for example
>
> Query::>
>
> SELECT t.* from (select _val FROM materials ) as t INNER JOIN
>
> "F2DEDF6E-393E-42BC-9BB3-E835A1063B30_862C7264-8C8A-4217-AFA4-30CD49AC050F_SECURITY".SecurityGroups
> ON t.EntityId = SecurityGroups.SGEntityId WHERE securityGroupId in
> ('25c8eff1-1607-4a57-bd88-b4be9a1c3b73') order by t.MaterialName offset 0
> rows fetch next 7000 rows only
>
> Exception::>
>
> Failed to parse query. Column "T.MATERIALNAME" not found; SQL statement:
> SELECT t.* from (select _val FROM materials ) as t INNER JOIN
>
> "F2DEDF6E-393E-42BC-9BB3-E835A1063B30_862C7264-8C8A-4217-AFA4-30CD49AC050F_SECURITY".SecurityGroups
> ON t.EntityId = SecurityGroups.SGEntityId WHERE securityGroupId in
> ('25c8eff1-1607-4a57-bd88-b4be9a1c3b73') order by t.MaterialName offset 0
> rows fetch next 7000 rows only [42122-197]
>
> Thanks.
>
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>
Re: SqlQuery Deprecated Since 2.8, please use SqlFieldsQuery
instead....How to get result as passing model Type with SqlFieldsQuery?
Posted by siva <si...@bizruntime.com>.
Hi,
It's working fine in "select _val from mytesttable" query but in case of sub
query or joins it's failing with an error like column not found
It's failing access column with and without table Aliases.
for example
Query::>
SELECT t.* from (select _val FROM materials ) as t INNER JOIN
"F2DEDF6E-393E-42BC-9BB3-E835A1063B30_862C7264-8C8A-4217-AFA4-30CD49AC050F_SECURITY".SecurityGroups
ON t.EntityId = SecurityGroups.SGEntityId WHERE securityGroupId in
('25c8eff1-1607-4a57-bd88-b4be9a1c3b73') order by t.MaterialName offset 0
rows fetch next 7000 rows only
Exception::>
Failed to parse query. Column "T.MATERIALNAME" not found; SQL statement:
SELECT t.* from (select _val FROM materials ) as t INNER JOIN
"F2DEDF6E-393E-42BC-9BB3-E835A1063B30_862C7264-8C8A-4217-AFA4-30CD49AC050F_SECURITY".SecurityGroups
ON t.EntityId = SecurityGroups.SGEntityId WHERE securityGroupId in
('25c8eff1-1607-4a57-bd88-b4be9a1c3b73') order by t.MaterialName offset 0
rows fetch next 7000 rows only [42122-197]
Thanks.
--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
Re: SqlQuery Deprecated Since 2.8, please use SqlFieldsQuery
instead....How to get result as passing model Type with SqlFieldsQuery?
Posted by Alex Plehanov <pl...@gmail.com>.
Hello,
Try this: "select _val from mytesttable"
чт, 21 янв. 2021 г. в 17:38, siva <si...@bizruntime.com>:
> Hi,
> I am using .net Ignite v2.9.1 and
>
> Since SqlQuery deprecated in documentation suggesting please use
> SqlFieldsQuery.
>
> what is the way to get result as Type using sqlfieldsquery?
>
> for example query
> select * from mytesttable
>
> Thanks.
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>