Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
powerbiexpert22
Impactful Individual
Impactful Individual

data validation

what is the step by step process to validate data in visual or KPI in power bi againts database in case of composite data model (fact on direct query mode and dimensions on import mode)

3 REPLIES 3
powerbiexpert22
Impactful Individual
Impactful Individual

Hi @rajendraongole1 

 

how do i validate m code correctness in power query?

Hi @powerbiexpert22 -Validating M code correctness in Power Query, especially in a composite model, involves checking syntax, previewing data, validating steps individually, handling errors gracefully, and considering DirectQuery limitations. 

 

The Power Query Editor makes it easy to pre-aggregate data during import. Technically, it's possible to import exactly the aggregate data you need for each visual. While DirectQuery is the simplest approach to large data, importing aggregate data might offer a solution if the underlying data source is too slow for DirectQuery.

 

DirectQuery in Power BI - Power BI | Microsoft Learn

 

Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!





rajendraongole1
Super User
Super User

Hi @powerbiexpert22 - you have to check the data model like identifying the fact and dimension tables. Ensure that relationships between fact and dimension tables are correctly defined in the Power BI model. we have to go through the aggregate or calculate metrics, as these measures to build visuals on power bi reports.

 Data validation:

 

Use SQL to query the database directly and retrieve the same metrics you calculated in Power BI. Ensure your SQL query mirrors the logic used in your DAX measures.

Export the data from your Power BI visual to Excel or CSV for comparison. Right-click on the visual and select export data option.

Compare the results from your direct SQL query and the exported data from Power BI. Ensure the totals, counts, and other aggregated values match.

Validate any new or changed data in the fact table. Check if incremental data changes in the DirectQuery source reflect accurately in the Power BI report.

you can also use performance analyzer to start recording, refresh your visuals, and check the DAX and SQL queries generated. Compare these with your manual SQL queries to ensure they align.

 

These are the main validation things we can look over. Hope i answered to your query.

 

 

Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!





Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors