Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to repopulate data with different filter condition (>1 time) in the same table

Hello,

I have data as below:

Untitled.png

What I'd like to do is to add 1 more column in qlikview table, named 'ReportingGroup' (1001,1002,1003, 1004).

I'd like this table to populate data 3 time

1)  with ReportingGroup = 1001, populate all the data

2)  with ReportingGroup = 1002, populate the data when Region = BKK

3)  with ReportingGroup = 1003, populate the data when Region = GTBKK

4)  with ReportingGroup = 1004, populate 1 record showing zero value (0 in every field)

How could i do this in Qlikview?

Would be much appreciated for your help...

1 Solution

Accepted Solutions
swuehl
MVP
MVP

A simple approach would be to just perform four auto-concatenated loads, maybe like

RESULT:

LOAD

1001 as ReportingGroup,

CustomerID, FirstName, LastName, Gender, Region, IncomeRange, EmploymentType

from Table;

LOAD

1002 as ReportingGroup,

CustomerID, FirstName, LastName, Gender, Region, IncomeRange, EmploymentType

from Table where Region = 'BKK';

LOAD

1003 as ReportingGroup,

CustomerID, FirstName, LastName, Gender, Region, IncomeRange, EmploymentType

from Table where Region = 'GTBKK';

LOAD

1004 as ReportingGroup,

0 as CustomerID, 0 as FirstName, 0 as LastName, 0 as Gender, 0 as Region, 0 as IncomeRange, 0 as EmploymentType

autogenerate 1;

View solution in original post

1 Reply
swuehl
MVP
MVP

A simple approach would be to just perform four auto-concatenated loads, maybe like

RESULT:

LOAD

1001 as ReportingGroup,

CustomerID, FirstName, LastName, Gender, Region, IncomeRange, EmploymentType

from Table;

LOAD

1002 as ReportingGroup,

CustomerID, FirstName, LastName, Gender, Region, IncomeRange, EmploymentType

from Table where Region = 'BKK';

LOAD

1003 as ReportingGroup,

CustomerID, FirstName, LastName, Gender, Region, IncomeRange, EmploymentType

from Table where Region = 'GTBKK';

LOAD

1004 as ReportingGroup,

0 as CustomerID, 0 as FirstName, 0 as LastName, 0 as Gender, 0 as Region, 0 as IncomeRange, 0 as EmploymentType

autogenerate 1;