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

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.

Reply
Anonymous
Not applicable

Ignore error resulted from data validation rules build in excel file from Power BI.

Hi there , 

Can anyone shed some light on method to ignore error resulted from data validation rules build in excel from Power BI ? 

 

- Excel file was implement data formating rules that return in "TBA" if user input incorrect format to cell. 

*Picture with error message in excel file if user input wrong format

SuMati_0-1603725980433.png

- When i uploaded to power bi ( data source from sharepoint ) it was showing error. 

SuMati_1-1603726096555.png

Can pls guide how to remove this error ? I cant replace error with a value as it needed to be in date format.

Thanks !

5 REPLIES 5
manikumar34
Solution Sage
Solution Sage

@Anonymous , 

 

could you please share the error screenshot by clicking on the error for more details to assist you better. 

 

Regards, 

Manikumar





If this helps, Appreciate your KUDOS!
Did I answer your question? Mark my post as a solution!


Proud to be a Super User!




Anonymous
Not applicable

Thank for the reply. 

Error from power bi. 

SuMati_0-1603797632259.png

 

amitchandak
Super User
Super User

@Anonymous , Click on an error and check what is error and share

 

refer how to handle error in power query
https://www.youtube.com/watch?v=OE6DPmKqN7s
https://www.youtube.com/watch?v=9-Lag0VOiTs

debug issue
https://www.youtube.com/watch?v=OE6DPmKqN7s



Anonymous
Not applicable

Thanks for the posts , will definetely check that out ! 

 

Error as below..  is there a method to have 1-time error clear ? 

SuMati_0-1603797671985.png

 

Hello @SuMati ,

Add code similar to this in query statement M.

"Replaced Errors" - Table.ReplaceErrorValues(-"Changed Type", ?" date", null-,"year",null-,"""report_count",null))

let
    Source = Excel.Workbook(File.Contents("xxxxxxxxxxxxx.xlsx"), null, true),
    Sheet1_Sheet = Source{[Item="Sheet1",Kind="Sheet"]}[Data],
    #"Promoted Headers" = Table.PromoteHeaders(Sheet1_Sheet, [PromoteAllScalars=true]),
    #"Changed Type" = Table.TransformColumnTypes(#"Promoted Headers",{{"date", type date}, {"year", Int64.Type}, {"report_count", Int64.Type}}),
    #"Replaced Errors" = Table.ReplaceErrorValues(#"Changed Type", {{"date", null},{"year",null},{"report_count",null}})
in
    #"Replaced Errors"

V-lianl-msft_0-1603877377242.pngV-lianl-msft_1-1603877388468.png

Best regards
Liang
If this post helps, then consider Accept it as the solution to help other members find it faster.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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