Forum Discussion
Collection not populating
- Apr 18, 2022
Hi ADumith , I downloaded and imported your app. I refreshed the source data to be my SP list and used the collection and filter elements I've shared and it seems to work fine. I would encourage annotating references wherever possible.
My SP list is structured like this:
My date source in the app is targeted at the list:
The 'OnStart' property is set to:
The gallery items is set to:
The first of your gallery fields is set to:
The second of your gallery fields is set to:
Without access to your source list I'm unsure what may be wrong at your end. I can use your app, redirect it and modify a few of the field names/targets and it appears to be working.
Hellojonlake
I'm really confused, there is no way for the filter to work, I don't know what else to try, I generated a new app to try and the result is still the same.
I send you the app, maybe you are able to see something that I don't see.
I don't know what to think.
It' not make sense,
Hi ADumith , I downloaded and imported your app. I refreshed the source data to be my SP list and used the collection and filter elements I've shared and it seems to work fine. I would encourage annotating references wherever possible.
My SP list is structured like this:
My date source in the app is targeted at the list:
The 'OnStart' property is set to:
The gallery items is set to:
The first of your gallery fields is set to:
The second of your gallery fields is set to:
Without access to your source list I'm unsure what may be wrong at your end. I can use your app, redirect it and modify a few of the field names/targets and it appears to be working.
- ADumithApr 20, 2022Iron Contributor
I finally did it.
I decided to create a new list from a database as you suggested and also create a new app.
So everything works perfect now.
We won't know what the problem really was but I think it was a data source.
Thank you so much for all the follow-up you did to this case, now I am going with something a little more complicated and it is for work anniversaries, I will create another question in case I need it.
Again, thank you so much, I really appreciate it
- ADumithApr 20, 2022Iron Contributor
Hello jonlake,
At first I thought that was the problem and it would be enough to do what you are recommending me; actually, that was what I was doing, but unfortunately that's not the problem.
I'll explain, I took the variable varMonth and assign the value 01 (January) and the filter worked!
The filter worked finally, so the problem is when I try to do the filter with the variable value or the field value, somehow there is no match between them.
Maybe if we change the type of the variable, I mean use a local one instead of global, or there is definitely a problem with the list and I have to redo it but from scratch, instead of importing it.
Any ideas?
- jonlakeApr 20, 2022Iron Contributor
Hi ADumith , I can see now what's happening. The import from Excel brought in the Mbirth data with a field name of 'field_4'. Even if you rename it, in a Flow you need to use the original name. The original name can be seen if you view your list settings, then hover over the field in question At the bottom of the screen you will see the URL for that field with the original name at the end of the URL.
I avoid importing from Excel if at all possible but I appreciate it can sometime be a quick way to import data. A method which provides for greater control is to import the Excel data into an Access database, do any data cleansing there, and then export to your SP site as a list.
I can also see that you date of birth field is set to 'single line of text'. Should that not be a date field?
If your Mbirth data is in 'field_4' your gallery items should be set to:
//filter the gallery items to only show those with a birth month matching the current month
Sort(Filter(colBirthDay,field_4=varMonth),field_3,Descending) - ADumithApr 20, 2022Iron Contributor
Good morning jonlake,
Look at the image.
Note that each field has its title.
But, when the collection is created, the title of the field is not brought, but rather an ambiguous title is placed, I mean, field_1 instead of FullName, field_2 instead of EmployeeEmail, etc.
I'm sure that's the issue source, so how to solve it.
Thanks again for your time and support
- jonlakeApr 19, 2022Iron Contributor
Hi ADumith, I noticed that your list contained a number of field headings with ambiguous titles, e.g. Field_01, Field_02 etc. I would first try to simplify the list and give names to the columns that are appropriate for the data they contain. It's possible that you have more than one field named the same, which may be confusing your gallery filter/sort. If you can create the collection then your access shouldn't present a problem.
- ADumithApr 19, 2022Iron Contributor
Hello jonlake
Well, now I don't know whether to laugh or cry.
On the one hand the app is fine, it works as expected, however I can't get it to work on my side.
Thinking a little more, if there was a problem accessing the SharePoint list, don't you think that the collection would not even be generated?
I imported the list from Excel, I didn't do it from scratch. Would have something to do with it?
I think I'll have to put a support ticket to Microsoft to review this case.
However, thank you so much for all the support you have given me.