Hi Folks,
I have automatically created an app using the CDS Contact entity as my data source resulting in the typical 3-screen phone app. Once the app was created, I added the Account entity as an additional data source and created a collection of each of the entities.
The Contact entity has a Many-to-one relationship with the Account entity. The field name on the Contact entity is _parentcustomerid_value with a field type=String and its display name is Company Name.
On my Contact entity collection, I can see _parentcustomerid_value and _parentcustomerid_type and it would appear from sample data on my trial environment that _parentcustomerid_type must equal either "account" or "contact".
My question is, how do I update these fields in the Contact entity, so that records are associated with their respective company in the Account entity? I've been unsuccessful in all my attempts to update my collection or the entities.
Here is an example of what I've been attempting (I only have two records in the Contact entity and they have separate last names, so I've explicitly filtered the one-and-only "Phillips" for simplicity sake):
Patch(colContacts, First(Filter(colContacts,lastname = "Phillips")),{_parentcustomerid_type: "account"})
My apologies if this is covered elsewhere in the PowerUser community KB. I am fairly new to PowerApps. However, in my fairly limited testing, I have had some good success creating one-to-many relationships with SharePoint lists I just don't want to go down the path of warehousing my Account/Contact data in SharePoint.
Please advise. Thanks!
PowerApps Version: 3.18042.26
Solved! Go to Solution.
Any update on the CDS Customer (or Account) funcationality? I am trying to filter a Gallery of Contacts based on a Drop Down control of Accounts. My two CDS entities (Contacts and Accounts) have a relationship and in Dynamics the Account is an available field for the Contact Entitiy, but the Account field is not available for any control that has Contacts as the data source in PowerApps. All I am trying to do is get a list of all contacts associated with a specific Account. Why is this so hard and what am I missing?
Hello -
Take a look at this blog as it has the details on how you can use these customer fields within your application: https://powerapps.microsoft.com/en-us/blog/owner-customer-and-regarding-for-canvas-apps/
Hope this helps!
Brandon
This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.
Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.
User | Count |
---|---|
29 | |
23 | |
22 | |
10 | |
9 |