web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Cross join or Cartesia...
Power Apps
Unanswered

Cross join or Cartesian Join of collections

(0) ShareShare
ReportReport
Posted on by

Hi,

 

Is it possible to do cross join or Cartesian join of two collections with no relation in Powerapps ?

 

Eg: Table 1 :

date

2020-04-01

2020-04-02

2020-04-03

 

Table 2 :

name

AA

BB

 

Expected result:

table 3:

date                name

2020-04-01     AA

2020-04-01     BB

2020-04-02    AA

2020-04-02    BB

2020-04-03     AA

2020-04-03     BB

 

I tried addcolumns, but it didn't work.

Any help would be great.

Categories:
I have the same question (0)
  • Drrickryp Profile Picture
    Super User 2024 Season 1 on at

    Hi @Anonymous 

    Unless there is either a 1:N or N:N relationship between the tables, I doubt that it is possible in PowerApps to create a join.  

  • Verified answer
    PowerAddict Profile Picture
    7,316 Most Valuable Professional on at

    I created 2 collections: 

    ClearCollect(C1, {date1: "2020-04-01"}, {date1: "2020-04-02"}, {date1: "2020-04-03"});
    ClearCollect(C2, {name2: "AA"}, {name2: "BB"});

    Then I created a collection C3 with the following expression: 

    ForAll(C1, ForAll(C2, Collect(C3, {date3: date1, name3:name2})))

    This is how my collection looks like: 

    Join.JPG

     

    Let me know if this is what you were looking for. 

     

    ---
    If you like this reply, please give kudos (Thumbs Up). And if this solves your problem, please mark this reply as a solution by selecting Accept as Solution. This makes it easier for others to find answers to similar questions. 

     

    Thanks!

    Hardit Bhatia

    Blog | Twitter | LinkedIn | Facebook | YouTube  |  Email

  • Drrickryp Profile Picture
    Super User 2024 Season 1 on at

    Good Job @PowerAddict  for thinking outside the box.  

  • PowerAddict Profile Picture
    7,316 Most Valuable Professional on at
    Thank you @Drrickryp! Means a lot coming from you!

    Thanks,
    Hardit Bhatia

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 717 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 329 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard