Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi
I am trying to build a solution as follows in power query.
1. initially I have loaded Sales ( fact data) and DimCustomer tables. All CustomerID in Sales(fact data) is available in DimCustomer table.
2. Next day when I loaded the tables I found there are some CustomerID in Sales(fact data) that is not in DimCustomer.
The reports do not relfect the true data.
3. What I want to achieve is
a) I would like to check the CustomerID in new Sales(fact data) is all available in new DimCustomer
b) if all available then load the new Sales(fact data) else retain the old Sales(fact data ).
@ImkeF , @OwenAuger can you help on this.
Best Regards
CheenuSing
One way to do this is to use dataflows to keep the customer info and use an error statement to fail the refresh if the data isn't consistent. Then your report can consume the dataflow which will have the most recent successful refresh.
Hi @artemus ,
Can you please share some links to achieve this in dataflows.
Cheers
CheenuSing
No, I don't think anyone has tried this yet.
To accomplish this, you would
if Table.CountRows(MissingCustomers) > 0 then error "Missing customers" else CustomerTable
Hi @CheenuSing
to my knowledge, that's not possible.
As an alternative I'd recommend to dynamically create dummy-entries in your DimCustomer instead.
Imke Feldmann (The BIccountant)
If you liked my solution, please give it a thumbs up. And if I did answer your question, please mark this post as a solution. Thanks!
How to integrate M-code into your solution -- How to get your questions answered quickly -- How to provide sample data -- Check out more PBI- learning resources here -- Performance Tipps for M-queries
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.