Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Announcements
BI & Data Trends 2021. Discover the top 10 trends emerging in today. Join us on Dec. 8th REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Contributor II
Contributor II

Field from map not found

I am trying to map the Item Desc field to TableMain then create a new field based on the contents in the Item Desc field however when I Load data I get an error message that says "The following error occurred:Field ‘Item Desc ‘ not found."

Here is my code

MapPop:

Mapping LOAD

    "Local" AS "Location ",

    "Item Desc"

 
FROM [lib://Data/Sheet2.xlsx]

(ooxml, embedded labels, table is Sheet2);

 
TableMain:

LOAD

    "Location ",

    "City",

    "State",

    "Country"

 
       ApplyMap('MapPop’, " Location ", null()) as " Item Desc, ",

 
       IF(WildMatch(Country,'*United States*') and WildMatch(Item Desc,'*Population*'),'Referencible','N/A')AS [Action]

 

FROM [lib://Data/Sheet1.xlsx]

(ooxml, embedded labels, table is Sheet1);

1 Solution

Accepted Solutions
Highlighted
Partner
Partner

TableMain:

LOAD

    "Location ",

    "City",

    "State",

    "Country"

 

       ApplyMap('MapPop’, " Location ", null()) as " Item Desc, ",

 

       IF(WildMatch(Country,'*United States*') and WildMatch(ApplyMap('MapPop’, " Location ", null()),'*Population*'),'Referencible','N/A')AS [Action]

 

 

FROM [lib://Data/Sheet1.xlsx]

(ooxml, embedded labels, table is Sheet1);

View solution in original post

4 Replies
Highlighted
Partner
Partner

Move the if statement into a preceding load
you are deriving Item Desc and trying to use it in same load statement
something like
load *,
IF(WildMatch(Country,'*United States*') and WildMatch(Item Desc,'*Population*'),'Referencible','N/A')AS [Action]
;
load
Location
......
Highlighted
Partner
Partner

Are you sure in your spread sheet 2, the column header for item description is called "Item Desc," with a comma at the end?

Highlighted
Contributor II
Contributor II

Tried that and it creates a synthetic key any other suggestions?
Highlighted
Partner
Partner

TableMain:

LOAD

    "Location ",

    "City",

    "State",

    "Country"

 

       ApplyMap('MapPop’, " Location ", null()) as " Item Desc, ",

 

       IF(WildMatch(Country,'*United States*') and WildMatch(ApplyMap('MapPop’, " Location ", null()),'*Population*'),'Referencible','N/A')AS [Action]

 

 

FROM [lib://Data/Sheet1.xlsx]

(ooxml, embedded labels, table is Sheet1);

View solution in original post