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: 
Not applicable

Condition is not working in Load script

Hi All,

Please find the attached Qvw and Data file.

I have a condition in data load script where

if([WBS Element]<>null(),[WBS Element],if(Len(Assignment)>=6,Assignment,H.Text)) as WBS_Code_Final

If the data in WBS Element field is empty then it should check for Assignment field. If the length of assignment field is >=6 it should take that value otherwise H.Test as the WBS_Final_code.

If the data is not null in WBS Element then WBS Element should be take as WBS_Code_Final.

Please let me know if you need any clarifications.

Regards,

Keerthi KS

1 Solution

Accepted Solutions
Kushal_Chawda

Please see the attached.

View solution in original post

4 Replies
Kushal_Chawda

Please see the attached.

robert_mika
Master III
Master III

if(len(trim([WBS Element]))>0,[WBS Element],if(Len(Assignment)>=6,Assignment,H.Text)) as WBS_Code_Final

Not applicable
Author

Thanks a lot

jonathandienst
Partner - Champion III
Partner - Champion III

You cant compare nulls like that. Use:

if(Not(IsNull([WBS Element])), [WBS Element], if(Len(Assignment) >= 6, Assignment, H.Text)) as WBS_Code_Final

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein