Skip to content

Civilizer Search Operators

suewonjp edited this page May 13, 2017 · 17 revisions

Civilizer Search Operators have been implemented to help users tune their search phrases so that they can get more fine-grained search results.

For instance, the 1st search phrase will likely match more Fragments ( thus, inefficient ) than the 2nd search phrase.

  1. big data databases
  2. "big data"/c tag:databases
    • Just don't care about the meaning of this search phrase for now.

More Fragments of the search results usually mean it would take more time until you reach exact information you would've targeted.
By using the Civilizer Search Operators you can filter out irrelevant Fragments from your results so your search will be more efficient.

There are two types of operators : Category Operators and Flag Operators:


βœ”οΈ Category Operators

These operators make your search keywords target one or more specific categories (content, title, tag, etc.) of Fragments.
You can always combine two or more of these operators.

  • :
    • Will match all of words for Fragment contents and titles.
    • When no Category Operator is specified, this operator will be used implicitly.
    • ex): big data will match Fragments whose content or title contains phrases such as data is big, big data, Big data, etc.
  • any:
    • Will match any of words for Fragment contents and titles.
    • ex) any: big data will match Fragments whose content or title contain phrases such as big animal, database, big data, etc .
  • tag:
    • Will match Fragments whose tags contain all of the words.
    • ex) tag:xml html will match Fragments having tags of xml and html altogether.
    • Unlike other category operators, tag: and anytag: can accept comma-separated list.
      • so the query above is equivalent to tag:xml, html.
  • anytag:
    • Will match Fragments having any of the specified tags.
    • ex) anytag:xml html will match Fragments having tags of xml or html or both.
  • title:
    • Will match Fragments with a title that contains all of the words.
    • ex) title:install printer will match Fragments with a title that contains install and printer altogether.
  • anytitle:
    • Will match Fragments with a title containing any of the specified words.
    • ex) anytitle:android ios will match Fragments with a title that contains any of android or ios or both.
  • text:
    • Will match all of words for Fragment contents.
    • ex)text: big data will match Fragments whose content contains phrases such as data is big, big data, Big data, etc.
  • anytext:
    • Will match any of words for Fragment contents.
    • ex) anytext: big data will match Fragments whose content contains phrases such as big animal, database, big data, etc.
  • id:
    • Will match Fragment id numbers.
    • ex) id: 1 3 5 9 will match 4 Fragments with id of 1, 3, 5, 9.

[ About Colon (:) ]
Note that a colon (:) has a significant meaning for Civilizer Search Operators.
If your search phrase happens to have a colon literally, wrap it with double quotation marks (") such as "some-keyword:".

[ Shorter forms (Since 0.9.0.RC6) ]
You can use shorter forms of operators to save some typing;

tag: is equivalent to t:
title: is equivalent to ti:
text: is equivalent to te:
any: is equivalent to a:
anytag: is equivalent to at:
anytitle: is equivalent to ati:
anytext: is equivalent to ate:

[ Search considering Tag Hierarchy ]
By default, tag keywords won't consider their hierarchies.
But you can target Fragments tagged with a specific tag or any of its descendants by attaching a '/h' Flag Operator. (See below)


βœ”οΈ Flag Operators

You can append these operators to the tail of a word (with slash) and control match requirements for that word.

  • /c
    • Case Sensitive;
    • ex) "Big Data"/c will match Big Data NOT big data
  • /w
    • Whole Word;
    • ex) device/w will match device NOT devices
  • /b
    • Beginning with;
    • ex) html/b will match html or html5 NOT xhtml
  • /e
    • Ending with;
    • ex)mail/e will match email or Gmail NOT mails
  • /r
    • Regular Expression;
    • ex) https?/r will match http or https or https:// NOT ftp
  • /-
    • Inverse;
    • Will return results not matching the pattern.
    • ex) android/- will match any word not containing android
  • /h
    • Considering Tag Hierarchy;
    • Will work only with Tag Category Operators ( :tag or :anytag ).
    • Will match each descendant of the tag as well as the tag itself.
    • ex) tag:business/h will match any Fragment associated with a tag business or any of its descendant tags
  • You can always combine two or more of these operators.
    • ex) Down/bc will match Download or Downside ( WON'T match download either UpsideDown )
  • /b, /e, /w operators are supposed to be used with words consisting of alphanumeric characters and underscore( _ ).
    • Do not use any of these operators when your search word contains non-alphanumeric characters except underscore ( ~{}()#$@,%-+ and others )

The above example of search phrase "big data"/c tag:databases will match Fragments that satisfy the following conditions at the same time:

  • Fragments whose content or title contains one or more words of big data:
    • Case MATTERS because of the /c Flag Operator
    • The search will match the exact phrase big data ( 'big' and space and 'data' ) due to the double quotation marks.
  • Fragments whose Tags contain a word databases.
Clone this wiki locally