Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I'm pretty new regarding QV. I have some coding background, but still I'm not ready to code by myself.
So far I have been working on the current script that I have (done by someonelse in the company), but I want to understand the basics first.
The code below is the one I'm trying to understand. It aims to calculate price where ValorNetoLC is the Revenue and Peso_Neto is the weight in KG.
Sum({<Id_Fecha={'<=$(xMaxFechaMesFin)'},TipoFCFact={'Producto Terminado'}>}ValorNetoLC_NETWR)/Sum({<Id_Fecha={'<=$(xMaxFechaMesFin)'},TipoFCFact={'Producto Terminado'}>}PESO_NETO)
The question I have here is what does this expression means <=$(xMaxFechaMesFin) doing ?? "Fecha and Mes are some variables that exist, but the xMax and Fin I can't find them.
Hope you can help me
Thanks in advance
Id_Fecha={'<=$(xMaxFechaMesFin)'}
This only includes those if which are less then xMaxFechaMesFin
Have a read
https://community.qlik.com/t5/Qlik-Design-Blog/A-Primer-on-Set-Analysis/ba-p/1468344
it is variable xMaxFechaMesFin
check your variables list
and it checking
Id_Fecha={'<=$(xMaxFechaMesFin)'}
means ID_Fecha <= xMaxFechaMesFin