Supplies are limited. Contact info@espc.tech right away to save your spot before the conference sells out.
Get your discountScore big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount
I have 2 different tables. I want to create a measure with sum of stock 1 ( filter pertaining to yesterdays date ) and stock 2
Table 1
Dist | rid | stock1 | date |
a | abs | 2 | 9-8-2021 |
b | xyz | 3 | 9-8-2021 |
a | abs | 4 | 10-8-2021 |
b | xyz | 5 | 10-8-2021 |
Last date in this table is previous day's. i.e. data of previous day gets updated daily
Table 2
Dist | WS id | stock2 |
2 | ||
3 |
expected ans
total stock =14
Solved! Go to Solution.
@Anonymous So like:
Measure =
SUMX(FILTER('Table 1',[date] = TODAY()-1),[stock1]) + SUM('Table 2'[stock2])
@Anonymous , Not quite well understood your issue. What I understood is you need to calculate Stock values since yesterday(Day-1).
I have 2 different tables. I want to create a measure with sum of stock 1 ( filter pertaining to yesterdays date ) and stock 2
Table 1
Dist | rid | stock1 | date |
a | abs | 2 | 9-8-2021 |
b | xyz | 3 | 9-8-2021 |
a | abs | 4 | 10-8-2021 |
b | xyz | 5 | 10-8-2021 |
Last date in this table is previous day's. i.e. data of previous day gets updated daily
Table 2
Dist | WS id | stock2 |
2 | ||
3 |
expected ans
total stock =14
@Anonymous So like:
Measure =
SUMX(FILTER('Table 1',[date] = TODAY()-1),[stock1]) + SUM('Table 2'[stock2])
@Anonymous Are those tables related to one another?
Sorry, having trouble following, can you post sample data as text and expected output?
Not really enough information to go on, please first check if your issue is a common issue listed here: https://community.powerbi.com/t5/Community-Blog/Before-You-Post-Read-This/ba-p/1116882
Also, please see this post regarding How to Get Your Question Answered Quickly: https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490
The most important parts are:
1. Sample data as text, use the table tool in the editing bar
2. Expected output from sample data
3. Explanation in words of how to get from 1. to 2.
I have 2 different tables. I want to create a measure with sum of stock 1 ( filter pertaining to yesterdays date ) and stock 2
Table 1
Dist | rid | stock1 | date |
a | abs | 2 | 9-8-2021 |
b | xyz | 3 | 9-8-2021 |
a | abs | 4 | 10-8-2021 |
b | xyz | 5 | 10-8-2021 |
Last date in this table is previous day's. i.e. data of previous day gets updated daily
Table 2
Dist | WS id | stock2 |
2 | ||
3 |
expected ans
total stock =14