Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Good day, everyone!
I have some throuble with expr. I need to get sum(Sales) over my filter.
On first page i got total sum, it work correct:
Sum({<t35PRDWAER = {'RUB'}>} DECNRPRDEC),
where t35PRDWAER field is currency, DECNRPRDEC is sales
On second page i want to get this, but it doesn't work:
Sum({<t35PRDWAER = {'RUB'}, BVRPBEDVTZ <= (VTRBEGDVTR + year - (365/BVRZAHWVTR))>} DECNRPRDEC),
where BVRPBEDVTZ is date of sale, VTRBEGDVTR is another date field, BVRZAHWVTR is something else.
Please, help me write expression correct.
UPD1: MY FALSE, FRIENDS, i forget to tell that i got 'YYYYMMDD' format in date fields!
UPD2: HERE IS EXAMPLE.QVF, take a look, friends!
Because i found a good idea in new topic so thats is solution:
i decided to make new field Flag which contains when payment make
so now i need to thing how to divide this two sum(sales) into 2 KPI in qlik sense: first year payments and next years
upd: and i find the decision
i use
1. Sum({<t35PRDWAER = {'RUB'}, FlagYearPayment = {'next'}>} DECNRPRDEC) for next years payments
2. Sum({<t35PRDWAER = {'RUB'}, FlagYearPayment = {'first'}>} DECNRPRDEC) for first year payments
still search for decision un expressions in qlik sense...
Sum(
{<
t35PRDWAER = {'RUB'},
BVRPBEDVTZ = {"<=$(=Date((VTRBEGDVTR + year - (365/BVRZAHWVTR))))"}
>}
DECNRPRDEC),
Hi,
Refer Set Analysis: syntaxes, examples for more on set analysis.
it particulary works, but not at the end! ,
can you please rewrite at this part {"<=$(=Date((VTRBEGDVTR + year - (365/BVRZAHWVTR))))"},
because Date() is convert all in () into date, but it incorrect. UPD1 in upperpost.
Try
{"<=$(=(VTRBEGDVTR + year - (365/BVRZAHWVTR)))"},
I tried to do like that, but it's doesn't work:
Sum(
{<
t35PRDWAER = {'RUB'},
date(BVRPBEDVTZ) = {<=$(=(date(VTRBEGDVTR) + year - (365/BVRZAHWVTR)))}
>}
DECNRPRDEC),
You cant use date(BVRPBEDVTZ) in set analysis.
Try BVRPBEDVTZ= {"<=$(=(date(VTRBEGDVTR + year - (365/BVRZAHWVTR))))"}
doesn't work ((
it doesn't work
provide sample data..