NoSQL: a non-SQL RDBMS
|
|
OperatorsThe NoSQL system comprises a set of programs called operators.
Each operator is a separate program module that performs a unique function on the data, usually reading from STDIN and writing the result to STDOUT. By contrast, NoSQL utilities are programs that usually do not read from STDIN not write to STDOUT. An example is the At one time NoSQL used to have extra operators, like body, see, etc. At some point I realized how useless they were, so I dropped them. After all they were just calls to ordinary UNIX utilities. There was really no point in providing special operators just for them, as their function could be done by applying those system commands directly. For instance:
Once again, this shows how powerful the UNIX operating system already is of its own, and how handy it can be for an additional package like NoSQL to be able to tap into this power without having to reinvent the wheel. Invoking NoSQL operators is straightforward: program [options] [arguments] where program is the name of the desired NoSQL program. Make sure the directory containing the NoSQL executables, usually /usr/local/nosql/bin/, is in your PATH. Most programs take a --help switch that will show the available command line options and arguments and provide some usage notes.
As an alternative to extending your shell PATH you may prefer to use the nosql program [options] [arguments] and likewise for a pipeline of NoSQL operators: nosql operator1 | nosql operator2 | ...
This comes at the price of an extra exec() system call for each operator in the pipeline, an irrelevant penalty when using NoSQL at the command-line, but somewhat more significant if NoSQL is used to back a busy web server or other heavily loaded system. Using the "nosql" shell wrapper instead of adding NoSQL directly to your path may be a necessity if you also need to use other system utilities which names conflict with those of certain NoSQL operators. For instance,
Such shorthands predates also on the corresponding commands of the orginal Hobbs' RDB system. Sample use cases for every NoSQL operator will eventually be provided in section Operators. Trackbacks (1) | New trackback | Comments (0) | Print |