Forum

Can anyone help me ...
 
Share:
Notifications
Clear all

Can anyone help me to rewrite this query? It works well with MySQL but not in snowflake db


Posts: 2
Guest
Topic starter
(@Chetan)
New Member
Joined: 4 years ago

select t1.*
from ISSUES t1
         left join ISSUE_HISTORY t2
                   on t1.ID in (select distinct ISSUE_ID
                                from ISSUE_HISTORY
                                where t1.ID = t2.ISSUE_ID);

 

Error: [42601][2031] SQL compilation error: Unsupported subquery type cannot be evaluated

 

1 Reply
Posts: 2
Guest
Topic starter
(@Chetan)
New Member
Joined: 4 years ago

Can you try this one and let me know? 

1. select t1.*
from ISSUES t1
left join ISSUE_HISTORY t2
on t1.ID in t2.(select distinct ISSUE_ID
from ISSUE_HISTORY t2
where t1.ID = t2.ISSUE_ID);

Reply

Self Learning Video Tutorials - Software Course

Leave a reply

Author Name

Author Email

Title *

Preview 0 Revisions Saved
Share: