Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
Oyandresen
Contributor II
Contributor II

Creating a list from an excel mapping

Hi,

I'm trying to add an excel mapping to my Qlikview report, to link Cost Centers to mapped item.

The excel spreadsheet looks like this:

mapping.PNGThe results I'm aiming for, would be a list showing:   

Cost CenterMapping
11A23-B25-D22
12A23-B25-D22
13B27
17D45
25A23-B25-D22

 

or:

Cost CenterMapping
11A23
11B25
11D22
12A23
12B25
12D22
13B27
17D45
D25A23
2 Solutions

Accepted Solutions
Saravanan_Desingh

Try this,

tab1:
CrossTable(Map,Value)
LOAD * INLINE [
    Cost Center, A23, B25, B27, D45, D22
    11, x, x, , , x
    12, x, x, , , x
    13, , , x, , 
    17, , , , x, 
    25, x, x, , , x
];

tab2:
NoConcatenate
LOAD [Cost Center], Concat(DISTINCT Map,'-') As Mapping
Resident tab1
Where Value='x'
Group By [Cost Center];

Drop Table tab1;

View solution in original post

Saravanan_Desingh

One more version,

tab1:
CrossTable(Map,Value)
LOAD * INLINE [
    Cost Center, A23, B25, B27, D45, D22
    11, x, x, , , x
    12, x, x, , , x
    13, , , x, , 
    17, , , , x, 
    25, x, x, , , x
];

tab2:
NoConcatenate
LOAD [Cost Center], Map As Mapping
Resident tab1
Where Value='x';

Drop Table tab1;

View solution in original post

6 Replies
Saravanan_Desingh

Try this,

tab1:
CrossTable(Map,Value)
LOAD * INLINE [
    Cost Center, A23, B25, B27, D45, D22
    11, x, x, , , x
    12, x, x, , , x
    13, , , x, , 
    17, , , , x, 
    25, x, x, , , x
];

tab2:
NoConcatenate
LOAD [Cost Center], Concat(DISTINCT Map,'-') As Mapping
Resident tab1
Where Value='x'
Group By [Cost Center];

Drop Table tab1;
Saravanan_Desingh

Output:

commQV45.PNG

Saravanan_Desingh

One more version,

tab1:
CrossTable(Map,Value)
LOAD * INLINE [
    Cost Center, A23, B25, B27, D45, D22
    11, x, x, , , x
    12, x, x, , , x
    13, , , x, , 
    17, , , , x, 
    25, x, x, , , x
];

tab2:
NoConcatenate
LOAD [Cost Center], Map As Mapping
Resident tab1
Where Value='x';

Drop Table tab1;
Saravanan_Desingh

Output:

commQV46.PNG

Oyandresen
Contributor II
Contributor II
Author

Thanks for the swift response!

I will try that 🙂

Oyandresen
Contributor II
Contributor II
Author

This solved my issue!

Thanks again!