Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Coming your way, the Qlik Data Revolution Virtual Summit. October 27-29. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Not applicable

Load Data in Qlikview

Hi All,

Can anyone please help me in writing the load script?

Please see the attached excel file i want column G and H to be created in load script and not in Excel with formula's as this is a sample data only

  • Fist i want to know the position for the same product id 1,2, 3 etc
  • Count total no's for all test for single row.
1 Solution

Accepted Solutions
Highlighted
MVP & Luminary
MVP & Luminary

Try:

Temp:

LOAD [Product Id], [Test Date], [Test 1], [Test 2], [Test 3], [Test 4]

FROM comm107533.xlsx (ooxml, embedded labels, table is Sheet1);

Result:

LOAD *

  , if(Previous([Product Id]) = [Product Id], rangesum(1,peek('Position')),1) as Position

  , rangesum(if([Test 1]='No',1,0)

            ,if([Test 2]='No',1,0)

            ,if([Test 3]='No',1,0)

            ,if([Test 4]='No',1,0)) as [Total No's]

Resident Temp

Order by [Product Id], [Test Date];

drop table Temp;

See attached qvw.


talk is cheap, supply exceeds demand

View solution in original post

2 Replies
Highlighted
MVP & Luminary
MVP & Luminary

Try:

Temp:

LOAD [Product Id], [Test Date], [Test 1], [Test 2], [Test 3], [Test 4]

FROM comm107533.xlsx (ooxml, embedded labels, table is Sheet1);

Result:

LOAD *

  , if(Previous([Product Id]) = [Product Id], rangesum(1,peek('Position')),1) as Position

  , rangesum(if([Test 1]='No',1,0)

            ,if([Test 2]='No',1,0)

            ,if([Test 3]='No',1,0)

            ,if([Test 4]='No',1,0)) as [Total No's]

Resident Temp

Order by [Product Id], [Test Date];

drop table Temp;

See attached qvw.


talk is cheap, supply exceeds demand

View solution in original post

Highlighted
Not applicable

Thanks Gysbert Wassenaar