cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Ramole
Impactful Individual
Impactful Individual

Inventory Lookup

Hi 

i have created inventory via SharePoint of products, qty, prices etc., and its over 2000 items and would like to make easy searching like searchbox so i can pull back data easy way, can you please tell how can i do it and whats best way, Am generating this from an SharePoint List , not sure if there is a better way.

 

 

Thanks 

Thank you
If this post helps, then please consider Accept it as the solution to help the others and consider giving it a "Thumbs Up."
1 ACCEPTED SOLUTION

Accepted Solutions

Hi @Ramole ,

1)you should create collection in one behavior property, not drop down's Items.

Please set the app's OnStart:

ClearCollect(collection1Ship,'Shipments ')

2)Since Choices function is used to return the choices of  Company value, not filter data, so you could directly use this function for sharepoint, not collection.

set the drop down's Items:

Choices('Shipments '.Company)

3)filter problem:
Could you tell me:
your filter rule? use what control, filter based on which column?

the fields data type?

where do you put the filter formula?

I could not find where your filter formula is related to the drop down and choices function. So please describe more clearly.

 

Best regards,

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

6 REPLIES 6
WarrenBelz
Super User III
Super User III

Hi @Ramole ,

You can look in any number of items as long as the operator and field type are both delegable.

For instance Equals = or StartsWith work on Text fields without Delegation issues.

Depending on how many items you have in the list, you can also collect over 2000 - this post of mine explains one way of doing it.

What and how are you expecting to use for your search?

 

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.

Ramole
Impactful Individual
Impactful Individual

Hi @WarrenBelz 

Whats best way to impalement search function on inventory dropdown or search, and can you give me the full code for search function an example normally i will be searching item number and product name.   

 

Thanks 

Thank you
If this post helps, then please consider Accept it as the solution to help the others and consider giving it a "Thumbs Up."

Hi @Ramole ,

I am happy to look at and guide you on aspects of your code after you have written it and explained the problems encountered, but I cannot write code for you - that is not the purpose of this forum.

Hi @Ramole ,

Firstly, since your record number is larger than 2000, you need to pay attention to use delegate functions only. Or else, you may get wrong result.

Please refer this to see the delegate functions for sharepoint list:

Item Number Text Boolean DateTime Complex [1]
Filter Yes Yes Yes No [4] Yes
Sort Yes Yes Yes Yes No
SortByColumns Yes Yes Yes Yes No
Lookup Yes Yes Yes No Yes
= Yes Yes Yes No [4] Yes
<, <=,<>, >, >= Yes [2] No No No Yes
StartsWith - Yes - - Yes
IsBlank - No [3] - - No

 

Secondly, since "in " and Search is not delegate, so I more suggest you use Filter and StartsWith to filter.

Formula should be like this:

Filter(listname,StartsWith(columnname,Textinputname.Text))

If you want to add more conditions, you just need to use "," to connect.

Filter(table,condition1,condition2,...)

Here's a doc about filter function for your reference:

https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/functions/function-filter-lookup

 

If you think StartsWith could not meet your demands, only "in" could. Then you need to use collection to avoid the effect of delegation.

Firstly save your list data to collection , then filter that collection. In collection, there's no delegation limit.

Formula like this:

ClearCollect(collection1,listname);
Filter(collection1,textinputname.Text in columname)

 

 

If you still have some problems, you're welcome to post here. I more suggest you show me more detailed demands, then I could give you more detailed solution.

 

 

Best regards,

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Ramole
Impactful Individual
Impactful Individual

Hi @v-yutliu-msft 

When i use ClearCollect the dropdown shows error for Company.value  please see the screenshot. 
Choices('Shipments '.Company).Value this if i use direct connection is fine even default works on without no problems but when i filter the collection i will get problems, here is the filter i am using : 
Filter(collection1Ship,Status.Value ="Open", StartsWith( Company.Value, TextSearchBox1_19.Text )
||TextSearchBox1_19.Text in 'Check Number' ||TextSearchBox1_19.Text in InvoiceNumber || TextSearchBox1_19.Text in TrackingNumber)

 

invl.pngcol.png

Thank you
If this post helps, then please consider Accept it as the solution to help the others and consider giving it a "Thumbs Up."

Hi @Ramole ,

1)you should create collection in one behavior property, not drop down's Items.

Please set the app's OnStart:

ClearCollect(collection1Ship,'Shipments ')

2)Since Choices function is used to return the choices of  Company value, not filter data, so you could directly use this function for sharepoint, not collection.

set the drop down's Items:

Choices('Shipments '.Company)

3)filter problem:
Could you tell me:
your filter rule? use what control, filter based on which column?

the fields data type?

where do you put the filter formula?

I could not find where your filter formula is related to the drop down and choices function. So please describe more clearly.

 

Best regards,

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Top Solution Authors
Top Kudoed Authors
Users online (2,093)