cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

unknown error occured

Hello,

 

I am patching data form a collection to an Excel file located on my One drive.

My app ahs been working fine for the last 2 months. But since yesterday, when I patch the data I sometimes get a message in a red band saying "an unknown error occured".

WHen the patch was finished, I checked, and the data had not been patched in my Excel file.

It was lost!!!

Does anyone know where this error is coming from / how to solve it?

And how to avoid losing data. This is really a big problem...

Many thanks,

10 REPLIES 10
RandyHayes
Super User
Super User

@Anonymous 

This can happen for a variety of reasons from the Excel file through the OneDrive connection to the connection for the App itself.

Unfortunately you have to plan for those potential issues in your app by using functions like Errors and checking connections.

Also, Excel tends to be a bit temperamental when used as a DataSource - you might consider moving to SharePoint or SQL if possible for the future as you'll have a little more control over them and there will be less temperamental issues.

 

I hope this is informative and helpful for you.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!
Anonymous
Not applicable

I see...


How can I test for errors while it is patching?

The patch of the collections happens in one go.

It's not like there is a loop where I can test for error between each record being patched...Can you provide any guidance?

@Anonymous 

This is going to depend entirely on how you are doing your Patch.  Can you share your formula that you are using and perhaps that will lead to some suggestions?

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!
Anonymous
Not applicable

ForAll(offline_records,Patch(l_data,Defaults(l_data),{
date:c_date,
dir:Text(c_dir),
var:Text(c_var),
per:Value(c_per),
for:Text(c_for)}))

@Anonymous 

I know we kind of hit on this subject in some of your other posts, but are you still having issues with this function and formula?

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

nvm

@dyee4613 

What issue or error are you experiencing with it?

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

I was dumb and named the columns in my data set the same as the fields in my app.  I realized I had those confused.  I fixed the names and it started working again.

Hi @dyee4613 ,

Please consider posting your findings. Believe it or not, there are times when full fledged PowerApps solutions will incorporate Excel Data as a Production-grade solution (not synced to OneDrive per se, but definitely stand alone Excel static data).

 

Any lessons you learn could help others.

 

Thanks for being part of the community!

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Community Call Conversations

Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (3,096)