I'm looking for a little help here.
I have a Combobox (named: MVPICombo1) that is drawing data from a table (named: ByProcedure) in a OneDrive excel file.
I also have a gallery (named: ByProcedureGallery) to display the results of the selected items in the combo box and have used the Distinct function to try and remove duplicates from both the combo box (which is filtering results by the column "CustomerName") and the gallery (which is displaying the values from the "Procedure" column for the results from the Combobox).
However, I would like the gallery to show both the Procedure and CustomerName values in two fields in each gallery item but I think I am getting my code all mixed up as I cannot get it to do it.
I think it has to do with the Items code for the gallery which is:
Distinct( Filter(ByProcedure, CustomerName in MVPICombo1.SelectedItems.Result),Procedure)
Below are other codes to the relevant controls and some pics to help add context.
- Field text label for each gallery item:
- MVPICombo1 (combobox) Items:
Distinct( Filter(ByProcedure, Procedure=Procedure),CustomerName
Any help is appreciated.
To simplify the problem, create two tables from your original file that contain the Procedures and the Customer names. Then use these in Dropdown or Combobox controls. You can create forms to add new procedures and customers to these tables. It seems to me that your app is flawed because it violates basic principles of database design. Please look at my blog posts on how to do it. https://powerusers.microsoft.com/t5/News-Announcements/Database-Design-Fundamentals-and-PowerApps-An...
Thank you very much for the help. I will have a good read through all your blog posts.
Quick question, I don't need my end users to add, edit, delete or refine any of the data in any way. This is purely a data viewing and filtering app to allow them to better use their data, e.g. view each procedure by the customer name. With that in mind, would you still recommend creating the two tables mentioned above?
The normalization of your table won't affect the end users ability to search the data and will probably optimize the searches. However, a poorly designed database will affect the developer's ability to add new records, make changes in existing records and remove records without affecting other records in the database.
Check out the on demand sessions that are available now!
Stay up tp date on the latest blogs and activities in the community News & Announcements.
Features releasing from October 2020 through March 2021
Check out the Power Platform Community Highlights