Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
Need to Create a inline table with the below Data.Getting Problem in the Expression Values
Could anyone help in Creating a inline table with the below 2 fields and their values.
Test:
Load * inline
[
ExpId, Expression
0,Above([Field1],0)*$(vVar(0)),
1,Above([Field1],1)*$(vVar(1)),
2,Above([Field1],2)*$(vVar(2)),
];
Thanks in Advance.
You can use a mapping (it doesn't like the characters '[' and ']' in your inline table, also the $ is trying to evaluate the variable). Just use different characters for those characters, then map them back like:
map1:
Mapping Load x, pick(match(x, '<', '>', '!'), '[', ']', '$') as y Inline [
x
<
>
!
];
Test:
Load ExpId, MapSubString('map1', Expression) as Expression inline
[
ExpId, Expression
0,'Above(<Field1>,0)*!(vVar(0))'
1,'Above(<Field1>,1)*!(vVar(1))'
2,'Above(<Field1>,2)*!(vVar(2))'
];
Please find attached.
Hope this helps!
You can use a mapping (it doesn't like the characters '[' and ']' in your inline table, also the $ is trying to evaluate the variable). Just use different characters for those characters, then map them back like:
map1:
Mapping Load x, pick(match(x, '<', '>', '!'), '[', ']', '$') as y Inline [
x
<
>
!
];
Test:
Load ExpId, MapSubString('map1', Expression) as Expression inline
[
ExpId, Expression
0,'Above(<Field1>,0)*!(vVar(0))'
1,'Above(<Field1>,1)*!(vVar(1))'
2,'Above(<Field1>,2)*!(vVar(2))'
];
Please find attached.
Hope this helps!
Hi Karthigayan,
table put into excel and load in qlikview ,instead punting inline table .
PFA .
You can try something like this or refer this link ABOVE Function
Test:
Load * inline
[
ExpId, Expression
0,Above(ExpId,0)*$(vVar(0))
1,Above(ExpId,1)*$(vVar(1))
2,Above(ExpId,2)*$(vVar(2))
];