Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Friends,
I have the below source file including the below 2 fields Level1 and Level2, using these two fields i have to get the COA field.
the conditions are:
1) if level 2 is having data that should reflect in the COA field,
2) if level 2 is null then it has to consider level1 data in the COA field
3) if the two fields are blank it has to take the above of that data
Is this possible to do in Qlikview?
Please help me....
Level1 | Level2 | COA |
Vehicle Loans | Vehicle Loans - Fixed Rate | Vehicle Loans - Fixed Rate |
Vehicle Loans - Fixed Rate | ||
Vehicle Loans - Fixed Rate | ||
Vehicle Loans - Variable Rate | Vehicle Loans - Variable Rate | Vehicle Loans - Variable Rate |
Vehicle Loans - Variable Rate | ||
Personal Loans | Personal Loans - Fixed Rate | Personal Loans - Fixed Rate |
Personal Loans - Fixed Rate | ||
Personal Loans - Fixed Rate | ||
Personal Loans | Personal Loans | |
Personal Loans |
ll
Try like:
If( Len(Trim(COA))=0, Peek(COA), COA) as NewCOA
Yes.
For first two requirements,
if( length(level2)>0,level2,
if(length(level2)=0,level1)) as COA
For third requirement can you please share sample qvw?
thanks
Khushboo
This could be solved with Peek() or Previous() ?
- Marcus
may be this at script:
=if(Level2<>null() or Level2<>'', Level2, IF(Level1='' or Level2='', Previous(Level1)) as COA
Dear Tresesco,
thank you for the quick reply.
i do not have a field COA, i have to create with existing fields.
any other idea?
HI,
Try like this
LOAD
*,
If( Len(Trim(Level2))> 0, Level2, Level1) as COA
FROM DataSource;
Hope this helps you.
Regards,
jagan.
Missed some points.
Try:
If(Len(Trim(Level2))=0, If(Len(Trim(Level1))=0, Peek(Level2), Level1), Level2) as COA
Hi friends,
i completed the requirement with you people help,
Facing an issue here that,
if u see my attachment, some of the values are not visible in my chart but they are populating in the list box.
what might be the issue?
Could you post some sample data?