cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
xzDan
Level 8

Bug - Selecting a Gallery's AllItems duplicates columns

Make a gallery, set its items to

Table({Choice: {Value: "Choice1"}}, {Choice: {Value: "Choice2"}})

 

Make a button, set its OnSelect to

ClearCollect(tbl,Gallery.AllItems)

 

The result:

 

GalleryBug.pnga
On the top row, both have the record {Value: "Choice1"}, on the bottom, both have {Value: "Choice2"}. This does not occur if using standard text , numbers etc.

2 ACCEPTED SOLUTIONS

Accepted Solutions
Super User
Super User

Re: Bug - Selecting a Gallery's AllItems duplicates columns

@xzDan 

Not sure what you are trying to achieve specifically, but your formula is the same regardless of a Gallery.

 

ClearCollect(tbl, Table({Choice:{Value: "Choice1"}}, {Choice: {Value: "Choice2"}}))

Produces the same results.  

 

Again, not sure what you are trying to get to, but you might want to try these combinations to get a better understanding of how the Collection works when defined that way:

Try:
ClearCollect(tbl, Table({Choice:1, Value: "Choice1"}, {Choice:2, Value: "Choice2"}))
AND try:
ClearCollect(tbl, Table({AChoice:{Value: "Choice1"}}, {Choice: {AValue: "Choice2"}}))

 

Hope this helps uncover Collections for you a little more.

 

 

 

 

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.

View solution in original post

PowerApps Staff ADobin
PowerApps Staff

Re: Bug - Selecting a Gallery's AllItems duplicates columns

Thanks for reporting this issue! We have a fix coming out very shortly, it only impacts the collection viewer and does not impact the actual data that is in the collections.

View solution in original post

6 REPLIES 6
Super User
Super User

Re: Bug - Selecting a Gallery's AllItems duplicates columns

@xzDan 

Not sure what you are trying to achieve specifically, but your formula is the same regardless of a Gallery.

 

ClearCollect(tbl, Table({Choice:{Value: "Choice1"}}, {Choice: {Value: "Choice2"}}))

Produces the same results.  

 

Again, not sure what you are trying to get to, but you might want to try these combinations to get a better understanding of how the Collection works when defined that way:

Try:
ClearCollect(tbl, Table({Choice:1, Value: "Choice1"}, {Choice:2, Value: "Choice2"}))
AND try:
ClearCollect(tbl, Table({AChoice:{Value: "Choice1"}}, {Choice: {AValue: "Choice2"}}))

 

Hope this helps uncover Collections for you a little more.

 

 

 

 

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.

View solution in original post

xzDan
Level 8

Re: Bug - Selecting a Gallery's AllItems duplicates columns

Hi, you're right, thanks.

 

I suppose it is a question about collections  then. Is there a reason it stores it twice for a record?

 

My reasoning for doing this was I have it so that the user enters one entry, and it is potentially split up into three pieces, and wanted a gallery with each item containing the record, so that my submit button isn't so messy with creating the records in that.

Super User
Super User

Re: Bug - Selecting a Gallery's AllItems duplicates columns

@xzDan 

I believe it is in the way it parses the JSON.  It does not observe the rules as you might expect it to and, in this case, trying to make an array within the record in a collect just will not work that way.  Smiley Frustrated

 

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
Super User
Super User

Re: Bug - Selecting a Gallery's AllItems duplicates columns

@xzDan 

Actually I just noticed that if I Collect from a datasource that has table items in it, it is duplicating all of them.

In other words, I collected from a SharePoint list and "typical" fields that have "values" are duplicated.  So, like the Author field is shown in the collection twice and all the others (lookups, choices, etc.)

 

However, I believe this is JUST the collection viewer that is having this issue.  I don't belive it is a sign of trouble in the Collection itself.

 

So...based on that, consider the second "Choice" column you were seeing in your collection viewer to be a "ghost". 

And, in fact, the collection was populating as you expected.

 

Don't know how long that has been happening, but it definitely is now.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
xzDan
Level 8

Re: Bug - Selecting a Gallery's AllItems duplicates columns

I also just tested this - you are correct. This is definitely a new bug

PowerApps Staff ADobin
PowerApps Staff

Re: Bug - Selecting a Gallery's AllItems duplicates columns

Thanks for reporting this issue! We have a fix coming out very shortly, it only impacts the collection viewer and does not impact the actual data that is in the collections.

View solution in original post

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

Top Kudoed Authors
Users Online
Currently online: 210 members 5,097 guests
Please welcome our newest community members: