When I Collect from CDS Data Source into Collection in canvas app designer, the lookup fields are not being populated even though I can see the lookup values when I bind the data source to the data table.
This is the sample formula that I used
ClearCollect(ContactCollection, ShowColumns(Contacts, "fullname", "createdby"))
And this is the output collection without any data in the lookup column.
Sometimes, the lookup columns show up and most of the times, they do not.
Is that a bug? And is there any fix/workaround solution for it?
Solved! Go to Solution.
If I need to display data from a related entity, I usually do a lookup.
Entity1 is parent
Entity2 is child
Let’s say Gallery1 lists Entity2 child records, and I have some controls outside the gallery that need to display information from the selected record. The information might need to be columns from the Entity2 record as well as its parent Entity1 record.
On select of the Gallery, I would set a variable for the selected record. Something like this:
Set(varRecord, Lookup([@Entity2], Entity2Id = Gallery1.Selected.Entity2Id)
Set(varParentRecord, Lookup([@Entity1], Entity1Id = varRecord.Entity2FieldName.Entity1Id)
That gives me 2 record variables to work with.
I usually also wrap those variable lookups with ShowColumns so that I can get the specific fields for the record that I want to work with. So, if there is a label or other control that needs to reference the column, I just make sure it’s included in the ShowColumns formula.
Running in the same problem.
This simple example, used in many Posts here as "Function" is still NOT function and a BUG.
In my case the Collection SearchMonthDates is created BUT no Data is inside.
When using the development environment the correct result is confirmed, but in the App not running.
I saw the bug exist already since over one year, sadly and poor behaviour ...
@SweetMaddin Is the value from "January" column referenced anywhere in your app? It is by design in Power Apps canvas app to retrieve the value which is used in the app.
Learn how to create your own user groups today!
Check out the new Power Platform Community Connections gallery!
Congratulations, the new Super User Season 2 for 2021 has started!
Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.