slamdata/purescript-search

Name: purescript-search

Owner: SlamData, Inc.

Description: A grammar and parser for Google-style searches on unstructured or semi-structured data.

Created: 2015-02-17 15:19:39.0

Updated: 2017-03-22 02:35:11.0

Pushed: 2017-04-11 20:12:57.0

Homepage: null

Size: 83

Language: PureScript

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

purescript-search

Latest release Build status

A grammar and parser for Google-style searches on unstructured or semistructured data

Installation
r install purescript-search
Documentation

Module documentation is published on Pursuit.

Examples
Simple Searches
  1. Search for everything containing the text “foo”:

    
    
    
  2. Search for everything not containing the text “foo”:

    
    
  3. Search for anything which is tagged with the foo tag:

    
    
  4. Search for anything:

    
    
  5. Search for anything containing text that starts with “uni”:

    
    
Predicate Searches
  1. Search for everything containing a foo field whose value is greater than 2:

    >2
    
  2. Search for everything containing a foo field whose value falls inside the range 0..2:

    0..2
    
  3. Search for everything that does not contain a foo field whose value falls inside the range 0..2:

    :0..2
    
  4. Search for everything that contains a foo field which contains a bar field which contains the text baz:

    bar:baz
    
  5. Search for everything that contains a baz field matching the SQL LIKE pattern _foo%bar:

    ~"_foo%bar"
    
  6. Search for everything that contains anything matching the glob pattern ?foo*bar:

    o*bar
    
  7. Search for everything that contains anything greater than 2:

    
    
  8. Search for anything containing a foo that starts with the text “uni”:

    uni*
    
  9. Search for anything containing a metadata attribute called path that contains /foo/bar:

    h:/foo/bar
    

This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.