Discussion board where members can get started with Qlik Sense.
I'm having trouble on Qliksens script all day.
I always get the Field <fieldname> not found error.
Here's the script:
[Region] & '-' & [Country] & '-' & [Brand] & '-' & [Media] as [Key]
,Date(Floor(num("Start Date")),'MM/DD/YYYY') as [StartDate]
,Date("End Date") as [EndDate]
(ooxml, embedded labels, table is sheet1)
Where [Key] <> '---';
I always get the
Field 'Key' not found
can somebody help me out here?
Go to Solution.
Key is not loaded yet when you use it in the where condition
you need to write the following:
where [Region] & '-' & [Country] & '-' & [Brand] & '-' & [Media] <> '---'
or you may use preceding load as follows:
Load * where Key <> '---';
(ooxml, embedded labels, table is sheet1);
You can not refer the calculated field created in same load statement in where clause.
Load * Where [Key] <> '---';
As other suggested You can not use derived field in same Load where clause.
There are 2 ways to use it.
1: using Preceding load
> which is already suggested by other 2 people
2: Using Resident Load
> try below
Your Current Script
Load * from Temp
where [Key] <> '---';
drop table Temp;
Well, 1st method gives best solution compare to 2nd.
Thanks everyone for your help!