Take the 2-minute tour ×
User Experience Stack Exchange is a question and answer site for user experience researchers and experts. It's 100% free, no registration required.

I am designing a search form where the user has to indicate if the field is required or optional, this will affect the way the query is built. For example if the user marks the field as required, in the query it would be an AND and if the user marks the field as optional in the query it would be OR.

I am thinking & and || as icons to represent them, but I think the users have not enough technical knowledge to know what it means. First thing I came up with was an asterisk (*) icon for required but I couldn't figure out for optional.

What do you suggest?

share|improve this question
4  
Can you give a bit more context to the problem? I'd like to understand who your users are and what they are using your search form to search for. –  Peter May 16 '12 at 19:04
    
use something tabular to let user write words into. then, user can tick-mark the important ones. –  user117 Oct 13 '12 at 13:19
add comment

5 Answers

I'm basing this on a fairly common design, which is to have a search field where everything is required, and another for OR'd options. Apple use that type of system in the finder's search tool, albeit a little more complex.

But for your application it would look like this...

mockup

download bmml source – Wireframes created with Balsamiq Mockups

The logic would be (dog AND brown AND (cat OR leopard OR gecko))

You can do a pure AND just by filling in the first field, and a pure OR just by filling in the second field.

You could also make the "All of the terms" and "Any of the terms" a drop down, so people can choose whether to do an AND or an OR. Like...

mockup

download bmml source

That is a little simpler and the query reads nicely, but it loses you a little expressive power - but unless you're getting into very complex search specifications (which are not really useful unless you have massive databases or need statistical outputs) probably isn't worth the effort for you or your users.

share|improve this answer
add comment

I'm actually against this, because it increases the amount of time a user has to take to read and decide what it means.

I'd rather tweak the search appliance/results set to optimize what's shown, based on your type of content.

For a Google Search Appliance I did at www.wirefly.com/search we used an "and" statement, because the "or" was diluting our results.

Test, tune, adjust accordingly.

share|improve this answer
1  
I agree. In the vast majority of cases I think the AND type of filtering offers all the functionality the user really needs. And it has the benefit of being the most common behavior among faceted search engines. –  Steve Wortham May 18 '12 at 21:01
add comment

Some ideas.

One, assume all optional unless a user makes it required:

    Search:
    +---------------+
    |               | [X] Make this required
    +---------------+

Two, do the google way and add some helper text:

    Search:
    +---------------+
    |               | 
    +---------------+
    Tip: Add a '+' before a term to make it required. 

Three, make it more of a sentence using a drop down:

    Search:
    +---------------+           +---------------+
    |               | [and \/]  |               | 
    +---------------+           +---------------+ 

As for icons, I agree that && and || are likely not universally known outside of math/programming. I think a '+' would make sense for and, however. And for or, it's such a short word, perhaps 'or' could suffice as an icon.

share|improve this answer
add comment

This might be silly and different , This is something that will go with the mental model of the users.

mockup

download bmml source – Wireframes created with Balsamiq Mockups

I don't have any data to back up.

share|improve this answer
    
I don't understand your second field. 'with or without this'. What would you get if you add in 'Dog' in the first field and 'Kitten' in the second - no kittens, or kittens and dogs? It makes no sense. –  JonW May 16 '12 at 20:32
    
I think the implication is that any keywords in the second box would be optional. Thus in your example it would be kittens or dogs. However, I completely agree this answer is not the best for this situation. I still think the question needs more context. –  GotDibbs May 16 '12 at 20:44
1  
@JonW Its different so there is the confusion, for your example the system will fetch all the results that should have "dog" and might or might not contain kitten. –  Pratheep ch May 16 '12 at 22:55
    
@JonW I do accept that this answer is not appropriate, I was just giving a different perspective –  Pratheep ch May 16 '12 at 22:55
1  
It's actually not a bad idea, but rather than saying "with to without this" I'd say "especially if it also has". That way it is more likely to be seen as a way of prioritising some search results, rather than excluding anything. –  Peter Bagnall May 18 '12 at 15:45
show 1 more comment

Ancestry.com has an interesting take on this kind of a query: below each field the user can specify whether the corresponding value must occur exactly as specified; when the constraint is not set, the system uses the extra information for ranking purposes. That is, OR is the default, but any field can be required to match (i.e., AND).

mockup

download bmml source – Wireframes created with Balsamiq Mockups

For expressing complex information needs this kind of flexibility is quite useful.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.