Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
qv_testing
Specialist II
Specialist II

Map to Fields

Hi Community,

I haev 2 tables

Table1:  (Like Master Table) Here i have duplicate ID, but service different.

IDService
10010ABC
10011BCA
10001CBA (Test)
10001CBA (Case)

Table2:

IDCategoryCost
10010Samsung1000
10011Nokia2000
10001Test3000
10001Case4000

I have created one calculated Dimension field...............

LOAD *, If(Service='ABC', 'Button1',

  If(Service='BCA', 'Button2',

  If(wildmatch(Service,'*Test*'), 'Button3',

  If(wildmatch(Service,'*Case*'), 'Button4')))) as Button;

If i am click Button 3 , in table 2 i have to map Test record only

10001Test3000

                                                                                              

If i am click Button 4 , in table 2 i have to map Case record only

10001Case4000

How to map these particular records..

PFA,

1 Solution

Accepted Solutions
sunny_talwar

May be try this:

LOAD ID,

  If(Service='ABC', 'Button1',

  If(Service='BCA', 'Button2',

  If(wildmatch(Service,'*Case*'), 'Button3',

  If(wildmatch(Service,'*Test*'), 'Button4')))) as Button,

  AutoNumber(ID&Pick(WildMatch(Service, '*Test*', '*Case*') + 1, 'NA', 'Test', 'Case')) as Key;

LOAD ID,

    Service

FROM

[https://community.qlik.com/thread/208840]

(html, codepage is 1252, embedded labels, table is @1);

LOAD AutoNumber(ID&Pick(WildMatch(Category, '*Test*', '*Case*') + 1, 'NA', 'Test', 'Case')) as Key,

    Category,

    Cost

FROM

[https://community.qlik.com/thread/208840]

(html, codepage is 1252, embedded labels, table is @2);

View solution in original post

2 Replies
sunny_talwar

May be try this:

LOAD ID,

  If(Service='ABC', 'Button1',

  If(Service='BCA', 'Button2',

  If(wildmatch(Service,'*Case*'), 'Button3',

  If(wildmatch(Service,'*Test*'), 'Button4')))) as Button,

  AutoNumber(ID&Pick(WildMatch(Service, '*Test*', '*Case*') + 1, 'NA', 'Test', 'Case')) as Key;

LOAD ID,

    Service

FROM

[https://community.qlik.com/thread/208840]

(html, codepage is 1252, embedded labels, table is @1);

LOAD AutoNumber(ID&Pick(WildMatch(Category, '*Test*', '*Case*') + 1, 'NA', 'Test', 'Case')) as Key,

    Category,

    Cost

FROM

[https://community.qlik.com/thread/208840]

(html, codepage is 1252, embedded labels, table is @2);

qv_testing
Specialist II
Specialist II
Author

Thank You Sunny....