Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am trying to evaluate one of two expressions, but neither works:
=Sum({1<cod_annomes ={$(#indicador1)}>} valor) [variable indicador1 = annomes&'AT-1a', and works perfectly)
OR
=Sum({1<cod_annomes =annomes & {'AT-1a'}>} valor)
But if it works...
=Sum({1<cod_annomes ={'201409AT-1a'}>} valor)
Is it an error syntax? Can i use a varible in an expression with set analysis?
Thanks in advanced, i tried all that i know and read a lot of questions of this forum...
Greetings
Hi,
You have Syntax Error
When you write set analysis the value you are comparing always enclosed in { }
Like in above expression
Sum({1<cod_annomes ={"annomes & {'AT-1a'}"}>} valor)
similarly when you are using Variable you have use =
Like in above expression
Sum({1<cod_annomes ={"$(=indicador1)"}>} valor)
Regards
Hi,
You have Syntax Error
When you write set analysis the value you are comparing always enclosed in { }
Like in above expression
Sum({1<cod_annomes ={"annomes & {'AT-1a'}"}>} valor)
similarly when you are using Variable you have use =
Like in above expression
Sum({1<cod_annomes ={"$(=indicador1)"}>} valor)
Regards
Yes we can use variable in expression with set analysis
=Sum({1<cod_annomes ={'$(#indicador1)'}>} valor) [variable indicador1 = annomes&'AT-1a', and works perfectly)
for text we need to add ' '
Thanks for your quick and interest Max,
The second expression that you gave me works perfectly, but not the one:
Sum({1<cod_annomes ={"annomes & {'AT-1a'}"}>} valor)
annomes is a field selectable and AT-1a a literal.
Its curious because in variable indicador1 i only do a concatenation like annomes&'AT-1a'
Do you know what can be happening?
Thanks for your help.
Thanks a lot Sasi,
I am trying to do concatenating annomes&'AT-1a' in the expression, but i fail....
Is any documentation about syntax in Qlikview?
Hi,
Basically issue is comming because of special character like {} and '
You have to use chr(39) for '
chr(123) for {
chr(125) for }
Try it in your searching string
Regards