Forum Discussion
mmoreira7
7 years agoFrequent Visitor
Error getting data by period
Hi everyone.
I am new to Power BI and I am facing this problem.
I´ve created this measures:
FAT ILIQUIDO = CALCULATE(SUM(FDOCDETAIL[TOTAL]);FDOCDETAIL[OPERATION_TYPE]="1")
FAT ILIQUIDO ANO ANTERIOR = CALCULATE( [FAT ILIQUIDO] ; SAMEPERIODLASTYEAR(FDOCHEADER[DOC_DATE]) )
If I take the two idividual values it gives me correct. But when I put them in a table with the week number the values turn in something that I dont know.
FAT LIQUIDO = sales
FAT ILIQUIDO ANO ANTERIOR = sales last year
Examples:
1. Values by month
2. Values by week
As you can see the values from last year aren't real for each week but the Total is correct.
Thank you in advance for your time.
2 Replies
- v-yuta-msftCommunity Support
Hi mmoreira7,
Modify your measure like pattern below and check if it can meet your requirement:
FAT ILIQUIDO = CALCULATE ( SUM ( FDOCDETAIL[TOTAL] ), FILTER ( FDOCDETAIL, FDOCDETAIL[OPERATION_TYPE] = "1" ) )Regards,
Jimmy Tao
- mmoreira7Frequent Visitor
Hello Jimmy,
Thank you so much for your help.
Unfortunatly all remais the same. It didnt work.
Any other suggestion?