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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / How to insert data fro...
Power Apps
Answered

How to insert data from a table in the Gallery screen?

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

I am having doubts on how I can code or read data from a table.

 

I would like to see in the first option the "Item_Code" field and in the second field below the name "Item_Name".

It's important to note that you would not like to affect the search and ordering code for the gallery. 

 

 

Help_PowerApp_00001.PNG
Categories:
  • RandyHayes Profile Picture
    76,299 Super User 2024 Season 1 on at

    @Anonymous 

    As long as you have those columns in your DataSource and you have connected your DataSource to the Gallery, you can quickly edit those labels in the "Fields - Edit" under the Gallery properties on the right properties pane.  

    There you can select whatever columns you have in your DataSource to display them.

     

    I hope that is helpful for you.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi, @RandyHayes for your quick answer.

     

    But...I'm not seeing exactly the field mentioned. Would these be featured? And what code would you use to extract the information from the table? 

     

    Appreciate your time.  

    Help_PowerApp_00002.PNG
  • RandyHayes Profile Picture
    76,299 Super User 2024 Season 1 on at

    @Anonymous 

    You are using CutomGallerySample as your DataSource!  Pretty sure you don't want the built-in sample data to be your data.  You will need to put your DataSource in the property and adjust your formula to the columns that are in your datasource.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hey @RandyHayes one more time! Thank you! 

     

    So...I took out a "Search Item" formula from the field and adding the name of the database. It worked as you instructed.

    But I have another issue:

    - How do I add a search item? (a mean the code and where?...on "TextSearchBox4"??? 

     

    Once again appreciate your time. 

    Help_PowerApp_00003.PNG
  • Verified answer
    RandyHayes Profile Picture
    76,299 Super User 2024 Season 1 on at

    @Anonymous 

    You need not worry about the Textbox to do anything.  In PowerApps, things "respond" to other controls, controls don't usually alter other things.

    So, looking at your original default formula for your Gallery Items Property is the place to start.

    You can see that it had two functions in it - the SortByColumns and the Search function.  You will need to apply those to your Gallery Items property as well.

    Consider altering this formula for your needs:

    SortByColumns(
     Search(yourDataSource, 
     TextSearchBox4.Text,
     "yourColumnYouWantToSearchInQuotes"),
     "yourColumnYouWantToSortByInQuotes",
     If(SortDescending1,
     SortOrder.Descending,
     SortOrder.Ascending)
    )

    This will give you similar functionality for searching and sorting that you were asking for, but you need to apply your datasource and your columns.

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 432 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 347

#3
WarrenBelz Profile Picture

WarrenBelz 254 Most Valuable Professional

Last 30 days Overall leaderboard