cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
cocoloco79
Regular Visitor

SQL table relationship

Hi there

 

I'm new to Power Apps and hope someone can help me out here.

 

I'm working on a canvas app to record produce waste.

It is very straight forward, I connected to a SQL server and created a table in the dataverse where I have added sql columns.

 

My issue is that when when a user selects a crop like carrots, the harvest delivery drop down should filter down to carrot only deliveries.

 

In SQL I would use this:

select top 1000000 'HarvestLoad Waste' as [Type], hd.HarvestLoadKey as [Key], cr.CropKey as ParentKey, hd.DocketNo as [Name]
from HarvestLoad hd
join Planting PL on PL.PlantingKey = hd.PlantingKey
join Variety va on pl.VarietyKey = va.VarietyKey
join Block bl on bl.BlockKey = pl.BlockKey
join Farm fa on fa.FarmKey = bl.FarmKey
join Supplier su on su.SupplierKey = fa.SupplierKey
join Crop cr on cr.cropkey = va.cropkey
where su.Active = 1 and hd.DateTimeDelivered >= dateadd(week, -6, getdate())
order by hd.DocketNo desc

 

How would I go about it in Power Apps? Help please..

0 REPLIES 0

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Community Call Conversations

Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (5,357)