cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
illusion615
Microsoft
Microsoft

Returned CDS data with empty lookup fields if using Filter/Lookup

I have 3 entities in CDS to store the many-to-many relationship between students and test campaign.

I import the data source into PowerApps as 'GMT Students', 'GMT Campaigns' and 'GMT Tests'

'GMT Tests' is the intersection table to record this many-to-many relationship, data structure as below

image.png

And I use below script to load the student, test campaign and the registration data into variables.

Set(CurrentStudent,LookUp('GMT Students',Email=Trim(txtEmail.Text)));
Set(CurrentTest,LookUp('GMT Tests','GMT Student'.'GMT Students' = CurrentStudent.'GMT Students'));
Set(CurrentCampaign,LookUp('GMT Campaigns','GMT Campaign'=CurrentTest.'GMT Campaign'.'GMT Campaign'));

The CurrentStudent was loaded as expect, but CurrentTest has some strange result which has no GMT Student and GMT Campaign included.

image.png

 

But it does exist when I look into the entity data

image.png

Actually it does work days before and I really don't know where is wrong.

Thanks for any help.

5 REPLIES 5
v-monli-msft
Community Support
Community Support

Hi @illusion615,

 

Have you tried to restore your app to a previous version to have a test? https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/restore-an-app

 

Regards,

Mona

Community Support Team _ Mona Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

Hi there, I had the same issue, I was told it is by design, but by all accounts they are looking to resolve the display issue.

 

I could not get it to work but I was told that you can still use the data in the field to do relational lookups but I could not get it to work.

 

 

Wells
Frequent Visitor

I think it can't be simply closed by "by design"Smiley Very Happy

At least, there should be a "best practice" suggested from product team on how to get data from join table.

Now I'm stucked here...anyone from support/PG team can help?

As mentioned in the following thread, seems like it's a bug (or by stupid design) and there is a workaround solution for that.

You need to add a column from the data source that is referencing in the lookup.

https://powerusers.microsoft.com/t5/Building-PowerApps-Formerly/Common-Data-Service-Returns-no-data-...

 

 

ClearCollect(ContactCollection,
    DropColumns(
        AddColumns(
            ShowColumns(Contacts, "fullname", "createdby"),
            "tempUserColumn",
            First(Users).User
        ),
        "tempUserColumn"
    )
)

 

This needs to be fixed urgently.  It has broken previously functioning apps in production which is unacceptable.

 

The behavior change is not consistent with "Lookup to second level tables" specified in this post back in August:  https://powerapps.microsoft.com/en-us/blog/preview-for-improve-data-source-experience-and-common-dat...

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

365 EduCon 768x460.png

Microsoft 365 EduCon

Join us for two optional days of workshops and a 3-day conference, you can choose from over 130 sessions in multiple tracks and 25 workshops.

Users online (1,913)