cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highwaywoman1
Frequent Visitor

Search function for gallery via document Name not working as expected :(

Hello, 

 

I have a gallery for a document library in Sharepoint.

 

The Name( with link to document) is the column I want to search by in my SearchBox.

I don't know the internal name and can not find it online. fileRef, linkToFile, etc none of those have worked so far. 

 

I want to be able to search by the uploaded document name or maybe have a calculated column that copies the Name into a different field (last resort! So hoping someone can help me out.)

 

Thank you so much, 

What I am using in my Gallery Items:

Search(
Filter(Repository, docType.Value=Dropdown_docType.Selected.Value),
SearchBox.Text,
"fileRef",
"description"
)

1 ACCEPTED SOLUTION

Accepted Solutions

@Highwaywoman1 ,

It seems you cannot (I tested it as well as I have never tried it before). You need to write the name to another text field as I suggested.

 

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.

Visit my blog Practical Power Apps

View solution in original post

4 REPLIES 4
RandyHayes
Super User
Super User

@Highwaywoman1 

Stay away from the calculated column!!

 

Keep in mind as well that many of the columns in a document library are already calculated columns.  This will impact searching. 

 

Also consider, how big is your list?  This is misleading for a document library.  A doc library is a list like any other list.  People often get confused thinking - the folder you are looking in is small.  But it is not relevant.  There is no such things as a folder in a document library.  They are all "simulated".  In reality the entire document library is a list.  And as such, every file and folder in the entire document library goes toward record count, and thus, delegation and record limits in your app play a big part.

 

I hope this is helpful for you.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!
WarrenBelz
Super User
Super User

Hi @Highwaywoman1 ,

Firstly do not use calculated columns - they will not help. I suggest you have a Text column and use Power Automate to copy the name in there when the file is created.

 

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.

Visit my blog Practical Power Apps

Fair enough on staying away from calc columns, thank you both @WarrenBelz @RandyHayes 

However, do you know how i can search by the Name (link to item) column in the document Library?

I can search by title or any other column. I just cant see that column in the library settings. I don't know what it's internal name is to reference it in my formula. 

@Highwaywoman1 ,

It seems you cannot (I tested it as well as I have never tried it before). You need to write the name to another text field as I suggested.

 

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.

Visit my blog Practical Power Apps

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Community Call Conversations

Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (5,414)