Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Search by more than one criteria of same type #7225

Open
NSimpraga opened this issue Jul 3, 2019 · 35 comments
Open

Search by more than one criteria of same type #7225

NSimpraga opened this issue Jul 3, 2019 · 35 comments
Labels
api ❤️ feature request 👩‍💻 ready for dev These issues are ready for someone to work on them - take your pick!

Comments

@NSimpraga
Copy link

Server (please complete the following information):

  • Snipe-IT Version v4.7.4 build 4107 (g49a255c8f)
  • OS: [e.g. Ubuntu, CentOS] Windows
  • Web Server: [e.g. Apache, IIS]
  • PHP Version 7.2.17

Is your feature request related to a problem? Please describe.
I am unable to search through assets by multiple criteria of the same type. For example: I have some equipment in locations 1-19 and 1-16. I am unable to search for all the assets that are in 1-16 and 1-19 at the same time, I need to do two searches at once. Hence, I also need to do two exports also.

Describe the solution you'd like
The simplest solution would be to use some kind of symbol to separate two or more values to search by. So if I want all assets that are either in 1-16 or 1-19 to show up, I'd just separate them with ';' in the search field.

Describe alternatives you've considered
The usage of quotation marks could also be added to be sure that whatever symbol is used as separation can also be used in a search if it is a part of an asset name, location, etc.

Additional context
Add any other context or screenshots about the feature request here.

@stale
Copy link

stale bot commented Sep 1, 2019

Is this still relevant? We haven't heard from anyone in a bit. If so, please comment with any updates or additional detail.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Don't take it personally, we just need to keep a handle on things. Thank you for your contributions!

@stale stale bot added the stale label Sep 1, 2019
@ajsy
Copy link
Contributor

ajsy commented Sep 1, 2019

Not Stale

@stale
Copy link

stale bot commented Sep 1, 2019

Okay, it looks like this issue or feature request might still be important. We'll re-open it for now. Thank you for letting us know!

@stale stale bot removed the stale label Sep 1, 2019
@stale
Copy link

stale bot commented Oct 31, 2019

Is this still relevant? We haven't heard from anyone in a bit. If so, please comment with any updates or additional detail.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Don't take it personally, we just need to keep a handle on things. Thank you for your contributions!

@stale stale bot added the stale label Oct 31, 2019
@NSimpraga
Copy link
Author

Not stale

@stale
Copy link

stale bot commented Nov 4, 2019

Okay, it looks like this issue or feature request might still be important. We'll re-open it for now. Thank you for letting us know!

@stale stale bot removed the stale label Nov 4, 2019
@cliff-LINKS
Copy link

+1

@stale
Copy link

stale bot commented Feb 27, 2020

Is this still relevant? We haven't heard from anyone in a bit. If so, please comment with any updates or additional detail.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Don't take it personally, we just need to keep a handle on things. Thank you for your contributions!

@stale stale bot added the stale label Feb 27, 2020
@NSimpraga
Copy link
Author

Not stale

@stale
Copy link

stale bot commented Mar 2, 2020

Okay, it looks like this issue or feature request might still be important. We'll re-open it for now. Thank you for letting us know!

@stale stale bot removed the stale label Mar 2, 2020
@tsilman-marquette
Copy link

Query - Can multiple search criteria verbiage be entered in the asset search bar?
Example1: laptop
Example2: laptop or desktop
Example3: laptop and desktop

Does the search bar follow specific boolean search methods?

@ajsy
Copy link
Contributor

ajsy commented Mar 4, 2020

I don't think so

@pbrink231
Copy link

pbrink231 commented Mar 4, 2020 via email

@stale
Copy link

stale bot commented May 3, 2020

Is this still relevant? We haven't heard from anyone in a bit. If so, please comment with any updates or additional detail.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Don't take it personally, we just need to keep a handle on things. Thank you for your contributions!

@stale stale bot added the stale label May 3, 2020
@tsilman-marquette
Copy link

This is still relevant.
If the wiki documentation included a more detailed description of how to parse searches, it might solve the problem. Multi-variate searches are needed as the database size and object variety numbers increase.

@stale
Copy link

stale bot commented May 3, 2020

Okay, it looks like this issue or feature request might still be important. We'll re-open it for now. Thank you for letting us know!

@stale stale bot removed the stale label May 3, 2020
@stale
Copy link

stale bot commented Jul 3, 2020

Is this still relevant? We haven't heard from anyone in a bit. If so, please comment with any updates or additional detail.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Don't take it personally, we just need to keep a handle on things. Thank you for your contributions!

@stale stale bot added the stale label Jul 3, 2020
@NSimpraga
Copy link
Author

Still relevant

@stale
Copy link

stale bot commented Jul 3, 2020

Okay, it looks like this issue or feature request might still be important. We'll re-open it for now. Thank you for letting us know!

@stale stale bot removed the stale label Jul 3, 2020
@stale
Copy link

stale bot commented Sep 2, 2020

Is this still relevant? We haven't heard from anyone in a bit. If so, please comment with any updates or additional detail.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Don't take it personally, we just need to keep a handle on things. Thank you for your contributions!

@stale stale bot added the stale label Sep 2, 2020
@cliff-LINKS
Copy link

cliff-LINKS commented Sep 2, 2020 via email

@stale
Copy link

stale bot commented Sep 2, 2020

Okay, it looks like this issue or feature request might still be important. We'll re-open it for now. Thank you for letting us know!

@stale stale bot removed the stale label Sep 2, 2020
@stale
Copy link

stale bot commented Dec 25, 2020

Is this still relevant? We haven't heard from anyone in a bit. If so, please comment with any updates or additional detail.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Don't take it personally, we just need to keep a handle on things. Thank you for your contributions!

@stale stale bot added the stale label Dec 25, 2020
@tsilman-marquette
Copy link

tsilman-marquette commented Dec 26, 2020 via email

@stale
Copy link

stale bot commented Dec 26, 2020

Okay, it looks like this issue or feature request might still be important. We'll re-open it for now. Thank you for letting us know!

@stale stale bot removed the stale label Dec 26, 2020
@Norjek
Copy link

Norjek commented Apr 13, 2021

Would be great if the search would support simple AND, OR and EXCLUDE parameters. So I could search for stuff...

  • from John but not Smith
  • from office north and office south
  • from office north or smith

Maybe using chars like &, | and - as parameters...

@Thomer73
Copy link

Thomer73 commented Dec 6, 2021

Any news about this nice feature?

@avielc
Copy link

avielc commented Mar 29, 2022

@snipe - Sorry to tag you on this mate, but this has been here for over a year without any official comment.
Any light you can shed on this?
You can only search for one value.
If I want to make a search for a computer model that is located in specific location, I can't. (as an example)

Thank you!

@snipe
Copy link
Owner

snipe commented Mar 29, 2022

No insight to offer at this time. We're really heads down on v6 and SCIM right now.

Many tickets have been here for over a year. Doesn't mean we won't get to them, just means other stuff has been higher priority.

@avielc
Copy link

avielc commented Mar 29, 2022

Thank you for answering, even if the team aren't prioritizing it, it's good to know what's the current status of things.

If you have any workaround for the search functionality or at the very least provide some clarity on how can we search for more than a single term. that would be really really helpful! (consider companies with 200+ computers on different locations, and you need to search for undeployed model in specific location to know what needs restock for example. this is kinda important for an inventory app.

Thanks again!

@snipe
Copy link
Owner

snipe commented Mar 29, 2022

@avielic - You can already search by location_id and status label type at the same time via API, or by drilling down into the location or status label listings and searching on the other via GUI.

@snipe snipe added 👩‍💻 ready for dev These issues are ready for someone to work on them - take your pick! ❤️ feature request api labels Mar 29, 2022
@avielc
Copy link

avielc commented Mar 29, 2022

@snipe sorry for the late reply.
Just tried now actually clicking the location (instead of navigating to the Settings > locations > clicking on location)
such a huge difference! and it makes it easier now!
Thanks again for helping this definitely lowers the need for this to be corrected for a multi-value search.

On another note, on 5.4.1 (probably before that too) the search in the assests, doesn't catch previous owners (e.g. history)
nor does the search in the activity log catches previous users that had an assest checked out to them.
just odd you know? (I probably need to create a proper issue card for that, huh?

@snipe
Copy link
Owner

snipe commented Mar 29, 2022

Thanks again for helping this definitely lowers the need for this to be corrected for a multi-value search

It's still on the list, it's just very difficult to execute well.

On another note, on 5.4.1 (probably before that too) the search in the assests, doesn't catch previous owners

I'm not sure if it was ever supposed to do that, but if so, it should be in a new bug.

@avielc
Copy link

avielc commented Mar 29, 2022

I'll try to find time to submit one tomorrow. today was a long day

@SonGokussj4
Copy link

Hi, so when I want to search something through an API, for example

# searching for name 'john'
# in 'atlanta' city
# which has model called 'wacom'

api/v1/hardware?search=john;atlanta;wacom;

This is still not possible and my only 2 options are if I'm right:

Option 1 - make more API calls, then do an intersection

# not per-languaga-specific syntax
result1 = api/v1/hardware?search=john
result2 = api/v1/hardware?search=atlanta
result3 = api/v1/hardware?search=wacom
result = result1.intersect(result2).intersect(result3) 

Option 2 - make 1 API call, then filter on server-side

# not per-languaga-specific syntax
result1 = api/v1/hardware?search=john
result = result1.filter(item => { return item.city.name.includes("atlanta") && item.model.name.includes("wacom") })

Is this correct?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api ❤️ feature request 👩‍💻 ready for dev These issues are ready for someone to work on them - take your pick!
Projects
None yet
Development

No branches or pull requests

10 participants