cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
AlesonITC
Helper II
Helper II

How can I make an inner Join os PowerApps?

I have 2 tables, one called "Items" with ItemId, Name.

And one called "Price" with Itemprice, ItemId.

We can make a Join Based on "ItemId".

How can I show ItemId,Itemprice,Name in the same table?

 

I read about "addcolumns", "filter", etc. But I can't do it and it seems too easy.

 

Thx for all, regards.

1 ACCEPTED SOLUTION

Accepted Solutions

Gallery1.Items = AddColumns(Items,"Price",LookUp(Price,ItemId=Items[@ItemId],Itemprice))
🙂

View solution in original post

8 REPLIES 8
Mike8
Solution Sage
Solution Sage

Hello,

I hope the following, may help you..


Button1.OnSelect= ClearCollect(Items,{ItemId:1,Name:"Item1"},{ItemId:2,Name:"Item2"});
ClearCollect(Price,{ItemId:1,Itemprice:10},{ItemId:2,Itemprice:20})

Button2.OnSelect = ClearCollect(Join,AddColumns(Items,"Price",LookUp(Price,ItemId=Items[@ItemId],Itemprice)))

Thanks for the answer, I dont want to do it with buttons, I need to show it in a table.

 

That Join that you use there I cannot use it.  ClearCollect(Join,AddColumns...

 

Need another solution.

 

Thanks anyways.

Gallery1.Items = AddColumns(Items,"Price",LookUp(Price,ItemId=Items[@ItemId],Itemprice))
🙂

View solution in original post

That's it!! it works fine, I accept it as a solution, but I have another question:

 

How can I make a "where" syntax?

 

Imagine I want to show only the items that price > 10, do you know how to do it?

 

Lot of thanks mate.

Filter(AddColumns(Items,"Price",LookUp(Price,ItemId=Items[@ItemId],Itemprice)), Price>10)

The documentation on filter function can help you

I got it mostly clear but It doesn't work, I'm showing you with a screenshot.

 

 

The images helps amigo.. 🙂

The beginning of the second line... ---> deno.Text  in '[Dim],[DimSIE]'
Can you change it into ---->   Denominacion= deno.Text    ?
Does it work?

Also you use the the filter function. I think its better to use the search function: 
https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/functions/function-filter-lookup

If not I would start from the beggininng.
Set the gallery items only with the addcolumns.
If it works, go to the filter..
If it works, go to the showcolumns..
The two tables that you use.. How many records do they have? More than 500? 

Exactly, 248 rows. I must say that It works all fine except the filter. I need to do the "Where" there.

 

I'm reading the search function.

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MBAS Attendee Badge

Claim Your Badge & Digital Swag!

Check out how to claim yours today!

secondImage

Are Your Ready?

Test your skills now with the Cloud Skill Challenge.

secondImage

Demo Extravaganza is Back!

We are excited to announce that Demo Extravaganza for 2021 has started!

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Top Solution Authors
Top Kudoed Authors
Users online (46,871)