Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Experts,
I need your help.
can anyone explain how can i write this sql script in qlik sense without having clause, i am stuck with having clause.
select date, SeqNo, ID, MachineType, count(SeqNo) as 'No of Sequence'
from ABC table
where date between date 1 and date 2 and MachineType in (6)
group by SeqNo, ID, Date, MachineType
having count(SeqNo)>1
Looking forward for you valuable Suggesions.
Thanks
Using preceding load, it can be happen as below
select date, SeqNo, ID, MachineType, count(SeqNo) as 'No of Sequence' from ABC table where date between date 1 and date 2 and MachineType in (6) group by SeqNo, ID, Date, MachineType having count(SeqNo)>1
would be written as
Load * where count(SeqNo)>1;
Load date, SeqNo, ID, MachineType, count(SeqNo) as 'No of Sequence'
from ABC
where date between date 1 and date 2 and MachineType in (6)
group by SeqNo, ID, Date, MachineType ;
Using preceding load, it can be happen as below
select date, SeqNo, ID, MachineType, count(SeqNo) as 'No of Sequence' from ABC table where date between date 1 and date 2 and MachineType in (6) group by SeqNo, ID, Date, MachineType having count(SeqNo)>1
would be written as
Load * where count(SeqNo)>1;
Load date, SeqNo, ID, MachineType, count(SeqNo) as 'No of Sequence'
from ABC
where date between date 1 and date 2 and MachineType in (6)
group by SeqNo, ID, Date, MachineType ;