Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Building Power Apps
Answered

data table - displaying records from 2 tables

(0) ShareShare
ReportReport
Posted on by 148

i have two data sources  - sample of some fields from each source:

Common link between the two tables is the ApptID.

 

Source 1 -Table 1 - ApptID , Date, Time, Name, Address, Phone  

Source 2- Table 2 - ApptID, Comments, Actions

Not all records in table 1 would have a related record in table 2

 

I am trying to display related records from both tables as single rows in a data table, so something like this:

ApptID , Date, Time, Name, Address, Phone, Comments, Actions

 

and if no  related records in table 2 then Comments and Actions in the data table would be blank.

 

I understand i need to change the items in my data table? but just how?  thanks

Categories:
  • Verified answer
    WarrenBelz Profile Picture
    146,668 Most Valuable Professional on at
    Re: data table - displaying records from 2 tables

    Hi @cheezy ,

    The Items of your Data Table would be something like this

    AddColumns(
     RenameColumns(
     Table1,
     "ApptID",
     "AID"
     ),
     "Comments",
     LookUp(
     Table2,
     ApptID = AID
     ).Comments,
     "Actions",
     LookUp(
     Table2,
     ApptID = AID
     ).Actions
    )
    	

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

  • StalinPonnusamy Profile Picture
    Super User 2024 Season 1 on at
    Re: data table - displaying records from 2 tables

    Hi @cheezy 

     

    We have to get using Addcolumns from other sources and bind to Datatable. For example

     

     

     AddColumns(
     IssueTracker,
     "EventName",
     LookUp(
     EventIItinerary,
     Event.Id = ThisRecord.ID
     )
     )

     

     

    In the above example, It gets all data from IssueTracker and Event name from EventItinerary source

     

     

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

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,668 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 66,004 Most Valuable Professional

Leaderboard