cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
boylec Frequent Visitor
Frequent Visitor

Re: Non-negative number required error while appending tables

NOTE:

I decompiled the assemblies that Power BI runs on and hooked up my debugger to drill down and find out whats going on and I was correct. The culprit is a bug in the Microsoft.MashupEngine.dll assembly, not something wrong with any data source. It will occur when the report is big enough.

 

Specifically:

The ReadPage and WritePage methods of the Microsoft.Mashup.EngineHost.Services.TransformingPagedStream class both use the following line (or equivalent because the decompiler may not be accurate as far as semantics)

 

this.inputStream.Seek((long) (page * this.inputPageSize), SeekOrigin.Begin);

 

'page' is a 32-bit integer here and so is 'this.inputPageSize'. So when the page number of the stream seek operation gets high enough, the page*this.inputPageSize multiplication operation eventually gets larger than the max 32-bit integer value of 2,147,483,647, which causes the operation to return a negative number due to the overflow.

 

That value is *then* converted to a long. What needs to happen is that the 'page' or 'this.inputPageSize' 32-bit integer needs to be a long in the first place so that the multiplication operation does not cause an overflow (or one of them needs to be cast at the time of the multiplication operation).

 

This negative number result is passed down through a few other functions until it hits the spot where we are seeing this exception in the stack-trace provided by the original poster.

 

Hope a dev can see this and patch it - seems like a pretty big bug.

 

Layman's terms:

This is a PBI Desktop bug, not a data source bug or something wrong with the way you built your report. The only thing you can really do until it gets patched is try and shrink your data source(s) so none of them hit this limitation.

Anonymous
Not applicable

Re: Non-negative number required error while appending tables

Thanks everyone for your hard work in trying to figure out this problem. Based on this Power BI Administrator's recommendation, I submitted a support ticket to Power BI support and included the information from this post as well as a link to this post for reference. The support site is telling me that I should hear back from Power BI support within one day. I'll let everyone know what I hear.

Anonymous
Not applicable

Re: Non-negative number required error while appending tables

Power BI support responded the same day that I submitted the support ticket (yesterday) and reached out to me to set up a screen sharing session to go through the issue we've been experiencing. The support person was very nice to work with. We captured some screenshots and gathered some log files, which will be passed on to the Power BI product development team for review.

motoroto Frequent Visitor
Frequent Visitor

Re: Non-negative number required error while appending tables

Hello, we are having the same issue. Did you get to solve it?

 

B rgds,

boylec Frequent Visitor
Frequent Visitor

Re: Non-negative number required error while appending tables

I’m working with a pro support rep on it the last two days. He said the latest October release of PBI Desktop should have patched the bug. I’ve yet to try it. Are you using the latest Power BI Desktop?
UAV-Test-Pilot Frequent Visitor
Frequent Visitor

Re: Non-negative number required error while appending tables

I am using PoweryQuery plugin for Excel 2016

 

Anybody know how I can get this update?

 

Excel version 16.0.4738.1000 64 Bit

Anonymous
Not applicable

Re: Non-negative number required error while appending tables

While the Power BI team was working on this fix, I modified my query to avoid loading such a large amount of data.

 

Recently, though, the Power BI support person I was working with followed up with me to let me know this problem has been fixed by the product team in the latest version of Power BI Desktop (December release).

 

I went back to replicate what I was originally trying to do, and I am no longer having the problem.

UAV-Test-Pilot Frequent Visitor
Frequent Visitor

Re: Non-negative number required error while appending tables

Any news if this will be pushed to PowerQuery for Excel as well?

Helpful resources

Announcements
Ask Amir Anything

Exclusive LIVE Community Event No. 2 – Ask Amir Anything

Next in our Triple A series: Ask Amir Netz questions about the latest updates, features and future.

October 2019 Community Highlights

October 2019 Community Highlights

October was a busy month in the community. Read the recap article to learn about some of the events and content.

New Solution Badges

New Solution Badges

Two waves of brand new solution badges are coming! Read the article for more information on our new community badges.

Analytics in Azure virtual event

Analytics in Azure virtual event

Experience a limitless analytics service built to ingest, prep, manage, and serve data for immediate use in Power BI.

Users Online
Currently online: 139 members 1,895 guests
Please welcome our newest community members: