Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

Viewing Associated Records in PowerApps

Posted on by Microsoft Employee

Hi, 

In my organization, we make use of a lot of N:1 relationships to organize our Accounts. For example, a customer account is associated to the account for his place of work, his physician, his church, and his wife's place of work. Currently, the best way to view an Account's associations is by using an Associated View. 

I am working with PowerApps to make browsing customer info on the go. Is there a way to display a list of records related to a record, in PowerApps? Searching for records and listing info for each record (i.e. fields for that record) and even related entities such as those where the account is in the "regarding" field is straightforward. My problem is that these related accounts do not appear on any fields in the original account form - they are simply related. 

Thanks in advance

*This post is locked for comments

  • RE: Viewing Associated Records in PowerApps

    Hi, to show the subgrid in the canvas app you just have to create a gallery or table and in the Items do like this:

    Filter(table; NameFieldThisTable.NameFieldParentTable=GalleryFromTheRecord.Selected.FieldName)

    Hope this works for you. I´ve spent the whole day figuring it out. The problem is that the field of the join must be a lookup. Otherwise it wont work. And, for some reason, the field "Company Name" in the Contact entity is not a lookup (I dont know why), so I had to create an equivalent field of the tipe lookup.

    Leave me a comment if you finally resolve it.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Viewing Associated Records in PowerApps

    Arun, here is a screen shot of the relationship from the Customizations menu. 

  • Arun Vinoth Profile Picture
    Arun Vinoth 11,613 on at
    RE: Viewing Associated Records in PowerApps

    Its' not about the environment, the problem with customizations.

    When you say there is a relationship between the entity records or no fields mapped, then how are they associated? How are you saying they are related?

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Viewing Associated Records in PowerApps

    Hi Barry, thanks for the reply.

    I seem to be doing fine with the general layout of building an app and filtering data from a previous screen. The problem I am having is displaying records "connected" to this ID when the parent record does not contain the associated records in any field. I am essentially wanting what an Associated View gives me, but in PowerApps. I don't have trouble using operators to sort through data that is represented by fields on the account form. I am struggling to display records which share a relationship, but don't appear as a field in each other's forms. Ultimately I think the major problem lies with how my organization set up the environment. 

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Viewing Associated Records in PowerApps

    Hi Ward,

    If you are struggling to filter from the previous screen, please use the following blog to give you tips on how to filter from a previous screen.

    As for how to display associated records, if the list is a single list based on the ID selected, then you can use this ID to filter the list and only show records connected to this ID.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Viewing Associated Records in PowerApps

    Thanks for the response. I'm having trouble building my formula for the gallery of associated records. I'm sure I'll be using the "Filter" function to display the records, but I don't know what operators to use to produce this list. I don't know how to display associated records when this association is not represented by any fields in the original record.

  • Arun Vinoth Profile Picture
    Arun Vinoth 11,613 on at
    RE: Viewing Associated Records in PowerApps

    You can design whatever the way you want - that’s the speciality of PowerApps (Canvas apps) - the pixel perfect.

    Design the first page with a gallery of Customers list (also search box), then on select you can navigate to next gallery of  associated records. There you can have search/filter drop down or even series of checkboxes to choose what they want to slice & dice with the records.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,235 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans