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 / Search multiple colums...
Power Apps
Answered

Search multiple colums with same box

(0) ShareShare
ReportReport
Posted on by 149

There are days when I think I'm just too dumb to even low code 🤷‍.

 

Let's say I have a simple Table with two columns, LastName and FirstName.

 

I created a gallery with those. I created a text box to enter my search value. When I type something in the textbox, I want everything that starts with that text to appear whether that be the last or the first name. Been at it for over an hour and can't make it work.

 

So the working code to just search the lastname is:

 

 

SortByColumns(
Filter(
[@TableName],
StartsWith(
LastName,
SearchBox.Text
)
),
"LastName",
Ascending

)

 

But now it also has to look for this same value in the FirstName column.

Categories:
I have the same question (0)
  • Verified answer
    Jeff_Thorpe Profile Picture
    6,085 Super User 2024 Season 1 on at

    Have you tries something like this:

     

    SortByColumns(
    Filter(
    [@TableName],
    StartsWith(
    LastName,
    SearchBox.Text
    ) ||
    StartsWith(
    FirstName,
    SearchBox.Text
    )
    ),
    "LastName",
    Ascending
    
    )
  • StefWS Profile Picture
    149 on at

    I had a lot more columns and wrapped in a sort and a bunch of If-statement. I've must 've left out a bracket or a , somewhere probably.

     

    Thanks!

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 Launch!

Jump in, show your community spirit, and win prizes!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Valantis Profile Picture

Valantis 421

#2
WarrenBelz Profile Picture

WarrenBelz 345 Most Valuable Professional

#3
Kalathiya Profile Picture

Kalathiya 278 Super User 2026 Season 1

Last 30 days Overall leaderboard