cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
MRauscher
Advocate II
Advocate II

Data from Tabele A to Table B with filter

Hello,
I want to create my first model-driven app and run into a problem while thinking about how to transfer data from one table to another. The data are all stored in Dataverse.
The following situation or requirement:
I have a table in which there are entries that, if a certain status is reached, should be displayed as a new selection option when creating a new entry in another table.
In a canvas app I could use filters etc. to get my result.
But since this new app is supposed to be a model-driven app, I can't get any further with my knowledge.

MRauscher_2-1637242996175.png

 

MRauscher_1-1637242878455.png

 

Thx Michael

1 ACCEPTED SOLUTION

Accepted Solutions
dpoggemann
Super User
Super User

Hi @MRauscher ,

 

If I read your question correctly, you could have a Lookup column on table B that utilizes table A as the source and then create a View on Table A that includes the statuses you would like to allow to be selected.  In the form for Table B, you can choose the View that is used to filter the lookup field, and you would choose the view you created.  Note, you need to click on the magnifying glass on the Lookup field to filter based on the defined view.

 

Hopefully this helps.  Please accept if answers your question or Like if helps in any way.

 

Thanks,


Drew

Hope this helps. Please accept if answers your question or Like if helps in any way.
Thanks,
Drew

View solution in original post

3 REPLIES 3
rampprakash
Super User
Super User

Hello @MRauscher,

 

You are absolutely correct, in Canvas we can use Filter Option. But when we are going with Model Driven App, you need to make an Retrieve call Using ODATA to perform this Operation.

 

Eg

 

On Load of Second Table, Pass the First Table ID and Get the values and Compare the Values is reached specific status or not. If yes then Set the value accordingly in Second Table..

 

I Have attached CRM Rest Builder, you can use the same for Generating ODATA query.

 

Please find my video on how to write JS on ONLOAD operation to perform the ODATA Call. LET me know if you need any help

 

Please mark as Answer if it is helpful and provide Kudos


Subscribe : https://www.youtube.com/channel/UCnGNN3hdlKBOr6PXotskNLA
Blog : https://microsoftcrmtechie.blogspot.com

dpoggemann
Super User
Super User

Hi @MRauscher ,

 

If I read your question correctly, you could have a Lookup column on table B that utilizes table A as the source and then create a View on Table A that includes the statuses you would like to allow to be selected.  In the form for Table B, you can choose the View that is used to filter the lookup field, and you would choose the view you created.  Note, you need to click on the magnifying glass on the Lookup field to filter based on the defined view.

 

Hopefully this helps.  Please accept if answers your question or Like if helps in any way.

 

Thanks,


Drew

Hope this helps. Please accept if answers your question or Like if helps in any way.
Thanks,
Drew
dpoggemann
Super User
Super User

Hi @MRauscher ,

 

If I read your question correctly, you could have a Lookup column on table B that utilizes table A as the source and then create a View on Table A that includes the statuses you would like to allow to be selected.  In the form for Table B, you can choose the View that is used to filter the lookup field, and you would choose the view you created.  Note, you need to click on the magnifying glass on the Lookup field to filter based on the defined view.

 

Hopefully this helps.  Please accept if answers your question or Like if helps in any way.

 

Thanks,


Drew

Hope this helps. Please accept if answers your question or Like if helps in any way.
Thanks,
Drew

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.

May UG Leader Call Carousel 768x460.png

June User Group Leader Call

Join us on June 28 for our monthly User Group leader call!

PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

PA.JPG

New Release Planning Portal (Preview)

Check out our new release planning portal, an interactive way to plan and prepare for upcoming features in Power Platform.

Users online (1,487)