Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
kinjal1645
Creator
Creator

Field not found error with load statement

Hello,

I am getting error for below script:

--> script

Table1:

SQL SELECT

          FIELD_A,  

          FIELD_B,

          FIELD_C

FROM .. ;

Table2:

LOAD FIELD_A,

Subfield(FIELD_C, '#', 1) as temp1;

SubField(FIELD_C, '#', 2) as temp2;

LOAD FIELD_A,

Subfield(FIELD_C, '$') as temp3;

LOAD FIELD_A, FIELD_C  

Resident Table1;

-->error

Field not found - <FIELD_C>

LOAD FIELD_A, FIELD_C 

Resident Table1;

Can someone help me with this?

Thank you

Kinjal

3 Replies
sudhirpkuwar
Partner - Creator II
Partner - Creator II

Try this

Table2:

LOAD *,

Subfield(FIELD_C, '#', 1) as temp1;

SubField(FIELD_C, '#', 2) as temp2;

//LOAD FIELD_A,

Subfield(FIELD_C, '$', 1) as temp3;

LOAD trace_id,

SubField(metainfo, '$') as Properties;

//LOAD FIELD_A, FIELD_C   

Resident Table1;

Anil_Babu_Samineni

If you look - You are doing Preceding load concept. So, I may look this way where you stuck

Table2:

LOAD FIELD_A,

Subfield(FIELD_C, '#', 1) as temp1;

SubField(FIELD_C, '#', 2) as temp2;

LOAD FIELD_A, FIELD_C

Subfield(FIELD_C, '$', 1) as temp3;

LOAD trace_id,

SubField(metainfo, '$') as Properties; // Where is the FIELD_C comes from? If you add like in RED, Your problem solvs

LOAD FIELD_A, FIELD_C  

Resident Table1;

FYI - https://help.qlik.com/en-US/qlikview/November2017/Subsystems/Client/Content/Scripting/preceding-load...

Please add me Anil_Babu_Samineni to interact faster when reply back. Speak low think High.

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
Anonymous
Not applicable

ur preceding load throw error.. so ...insted of using preceding load 3 time you can write this way..

Table1:

SQL SELECT

          FIELD_A,   

          FIELD_B,

          FIELD_C

FROM .. ;

Table2:

LOAD FIELD_A,

Subfield(FIELD_C, '-', -1) as temp1,

SubField(FIELD_C, '-', -2) as temp2,

Subfield(FIELD_C, '-', 1) as temp3;

LOAD FIELD_A, FIELD_C   

Resident Table1;