Nested queries
Hi Guys,
This Nested query is not working for some reason, but they work fine when executing separately ?
select id from FDRD_Com.List where vehicle in (select Car from FDRD_Com.Prod where ProductLineName='Toyota' and Car is not null)
Thanks
Product version: Ensemble 2018.1
Discussion (0)0
Comments
IN is expecting a list.
Did you ever try
selectidfrom FDRD_Com.List where vehicle IN
(selectLIST(Car) from FDRD_Com.Prod where ProductLineName='Toyota'and Car isnotnull)
on the sub select ?
different approach:
SELECT LI.id from FDRD_Com.List LI
JOIN FDRD_Com.Prod PR
ON LI.vehicle = PR.Car
WHERE PE.ProductLineName='Toyota'AND PR.Car isnotnull-- might be obsoleteLIST didn't work but the Join did, thanks you very much Robert.
As I recall, Nest queries didn't work well if all in the old Cache versions so not sure if they improved it !?