Forum Academy Marketplace Showcase Pricing Features

(Solved) Searching against a list

Hi,

I’ve encountered a problem when it comes to searching data contained in a list on a user.

Example:

User 1 Is searching for 1231 within User 2’s list that contains the values 1231 , 223 , 225 this works fine if User 2 only has 1231 in the list but when multiple values are entered it cannot find them (assuming because , is added)

Does anyone know of away around this?

Hi Josh,

In your example, are you typing in “1231, 223” into an input element? If so, the repeating group will display zero entries; it will not display two entries (with those being 1231 and 223) since 1231 doesn’t contain 223 and 223 doesn’t contain 1231. However, if you only enter “1231”, it will display all 1231 matches in the repeating group when you’re searching a list. If the set up is correct it should look something like this:
Editor:


Preview:

If you’re searching through a list created by a user you would add an additional constraint to the repeating group search which would be something like “Created By = Current Page User”

Not quite what im after.

User 1s value is not entered by a user. Basically what happens is if User 1 is viewed by User 2 then User 2 adds User 1s unique number to a list. When User 2 then looks at the search results User 1 cannot be displayed as Users 1s unique number is now stored in User 2s list. The search is meant to look through Users 2 list to determine what results should be shown.

So in your example, if you’re looking to store profiles - you could have User 2 have a List of Users, instead of a list of unique texts. The setup could be Field Name: Stored Profiles, Type: User, List: Yes. Then in the search, the repeating group type would be User, the source could be User 2’s Stored Profiles, and set up constraints on any field within the User data type in order to create search functionality.

1 Like

Alright didn’t know you could do that :slight_smile:

Will give that a shot and see how I get on cheers!

1 Like

Ah almost!

Except I can’t have the data source be User 2s Stored Profiles. I need the exclusions to be from the entire list of users in the database.

Hmmm…

Tried to search by Users stored in a list and this has not worked either. I’m drawing up blanks as to how to get this to work.

Actually – a way better way to do it would be

Data Source: “Current Page User’s Stored Profiles: filtered by” then add constraints:

The previous way you had it would work better as I cant limit the search to only the stored profiles on the user.

Thats the full search criteria. The last criteria still does not work however…

Heres how the profiles are stored in the list…

By last criteria not working are you saying that the results in the repeating group are displaying names that are in Current Page User’s List of Stored Profiles, though you do not want that to happen?

If so, is the data source for the page definitely User, and displaying data of User 2? Using the constraint Current Page User without that being defined on the page you are on, will show all results (if there’s no data about a user, then there’s no data on a list). Switch that to Current User, and as long as you’re logged in with an account that has a list of Stored Profiles, it should function the way you’d like it to.

You’re correct that is exactly what is happening.

I’ve switched it to current user and tested with the account that has them stored however still no dice. The results still show for profiles that are already stored.

Do the test accounts have names in the App data or are they blank?

They have names.

I’ve also tried comparing phone numbers. I also tried by setting up a new field type user and copied the user data to that then compared that to the stored profile list.

Hmm ok,

I’ve tried it without any other search criteria and that has actually worked… so the problem only appears when the other search criteria is used… yet the other search criteria works perfectly fine on its own >_<

Hmmm, can you copy paste everything with workflows into a page on the forum app?

Fixed it…

I moved the criteria that I wanted to the top and the re-added everything else underneath. That has seemed to have solved the issue.

Thank you so much for your help.

You can check out what im doing here - https://grabastudent.bubbleapps.io/index/ theres no verifications for signups just because im still testing so you can use a fake email. Note the design is still stock just working on functionality.

This is what the search criteria now looks like:

1 Like

Awesome! And my pleasure! I just created a test account for your site and it looks amazing!! Such a great app idea! :slight_smile: Best of luck!!

1 Like

Hi man, I am having trouble with a similar problem, the difference is that I need to do a search in a list of geographical address. I would appreciate if you could give me a hand. Here is the link for a more complete explanation of the issue:

Thanks!