The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.
Hi,
I am currently facing an issue while using Snowflake sql query as source data for my Power BI report.
I am using simple Select * From (my database_Table name_view name) but it throws the following error.
Unexpected error: Ticks must be between DateTime.MinValue.Ticks and DateTime.MaxValue.Ticks.
Parameter name: ticks
Details:
Microsoft.Mashup.Evaluator.Interface.ErrorException: Ticks must be between DateTime.MinValue.Ticks and DateTime.MaxValue.Ticks.
Parameter name: ticks ---> System.ArgumentOutOfRangeException: Ticks must be between DateTime.MinValue.Ticks and DateTime.MaxValue.Ticks.
Parameter name: ticks ---> System.ArgumentOutOfRangeException: Ticks must be between DateTime.MinValue.Ticks and DateTime.MaxValue.Ticks.
Parameter name: ticks
at System.DateTime..ctor(Int64 ticks)
at System.DateTimeOffset..ctor(Int64 ticks, TimeSpan offset)
at Apache.Arrow.TimestampArray.GetTimestampUnchecked(Int32 index)
I am not sure why it is throwing an error. It works fine when run in Snowflake.
Any help would be appreciated.
Thank you
Solved! Go to Solution.
Hi @JD_Khan
Power BI Error: Invalid Timestamp Range
Power BI cannot handle timestamp values earlier than 01/01/0001 or later than 12/31/9999. If your view contains dates outside this range, you’ll encounter processing errors.
How to Fix It:
Option 1: Filter Out Invalid Timestamps in SQL
Update your Snowflake SQL query to exclude any date values that fall outside the supported range.
SELECT *
FROM your_view
WHERE your_timestamp_column BETWEEN '0001-01-01' AND '9999-12-31'
Option 2: Convert Timestamps to Strings (if date functionality isn't needed)
SELECT
CAST(your_timestamp_column AS STRING) AS your_timestamp_column
FROM your_view
Option 3: Clean Data at the Source
If invalid dates occur regularly, consider one of the following:
🌟 I hope this solution helps you unlock your Power BI potential! If you found it helpful, click 'Mark as Solution' to guide others toward the answers they need.
💡 Love the effort? Drop the kudos! Your appreciation fuels community spirit and innovation.
🎖 As a proud SuperUser and Microsoft Partner, we’re here to empower your data journey and the Power BI Community at large.
🔗 Curious to explore more? [Discover here].
Let’s keep building smarter solutions together!
Hi @JD_Khan ,
Thanks for contacting the Fabric Community. In addition to @Akash_Varuna response, I recommend reviewing @grazitti_sapna solution as well, it could be helpful for your scenario.
Please try the suggested approaches, and if you need further assistance, feel free to reach out.
If your issue is resolved, kindly mark the appropriate response as the Accepted Solution so it can help others facing a similar issue.
Regards,
Yugandhar.
Thank you all for your responses. I found out that there is a Snowflake integration column from the source view which was the reason for this error. So I just skipped that column as I didn't need it. and it worked.
Hi @JD_Khan ,
Thanks for your response. If your issue is resolved, please consider marking it as the accepted solution this helps other community members find answers more easily.
Yugandhar,
CST Member.
Hi @JD_Khan ,
Thanks for contacting the Fabric Community. In addition to @Akash_Varuna response, I recommend reviewing @grazitti_sapna solution as well, it could be helpful for your scenario.
Please try the suggested approaches, and if you need further assistance, feel free to reach out.
If your issue is resolved, kindly mark the appropriate response as the Accepted Solution so it can help others facing a similar issue.
Regards,
Yugandhar.
Hi @JD_Khan
Power BI Error: Invalid Timestamp Range
Power BI cannot handle timestamp values earlier than 01/01/0001 or later than 12/31/9999. If your view contains dates outside this range, you’ll encounter processing errors.
How to Fix It:
Option 1: Filter Out Invalid Timestamps in SQL
Update your Snowflake SQL query to exclude any date values that fall outside the supported range.
SELECT *
FROM your_view
WHERE your_timestamp_column BETWEEN '0001-01-01' AND '9999-12-31'
Option 2: Convert Timestamps to Strings (if date functionality isn't needed)
SELECT
CAST(your_timestamp_column AS STRING) AS your_timestamp_column
FROM your_view
Option 3: Clean Data at the Source
If invalid dates occur regularly, consider one of the following:
🌟 I hope this solution helps you unlock your Power BI potential! If you found it helpful, click 'Mark as Solution' to guide others toward the answers they need.
💡 Love the effort? Drop the kudos! Your appreciation fuels community spirit and innovation.
🎖 As a proud SuperUser and Microsoft Partner, we’re here to empower your data journey and the Power BI Community at large.
🔗 Curious to explore more? [Discover here].
Let’s keep building smarter solutions together!
Hi @JD_Khan Could you inspect timestamp columns in Snowflake for out-of-range values and filter them using WHERE timestamp_column BETWEEN '1753-01-01' AND '9999-12-31'? Cast problematic timestamp columns to VARCHAR in your SQL query to bypass incompatible ticks. Disable query folding in Power BI to ensure filtering or casting occurs in Snowflake before data import. Also, ensure Power BI and the Snowflake connector are updated to the latest versions for better compatibility.
User | Count |
---|---|
65 | |
61 | |
60 | |
53 | |
30 |
User | Count |
---|---|
180 | |
88 | |
71 | |
48 | |
46 |