Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

sql sub-query in Qlik - urgent

Hello All,

Someone please help me. How can I create a load statement for the following SQL query.

select LocationId,MainVesselId FROM [dbo].[tbl_Data_VesselActivity] where SlNo in (selectmax(SlNo) FROM [dbo].[tbl_Data_VesselActivity] group by MainVesselId).

Please help. It's urgent.


Thank You,


Rahul

10 Replies
rupalimane1390
Contributor III
Contributor III

What do we do in case where in query is coming from different schema other than main select statement?

I tried SQL select LocationId,MainVesselId FROM [dbo].[tbl_Data_VesselActivity] where SlNo in(selectmax(SlNo) FROM [dbo].[tbl_Data_VesselActivity] group by MainVesselId). 

statement but it gives error ' Table or view does not exist'.