ioda logo

ioda fulltext engine

Interface documentation of the command line program joda

The function list:

Indexing one file (or database record) from file or pipe
joda -s database wordListFile [fileRef] [datestamp] [infobyte] [id]

Examples:

Indexing multiple files from pipe:
joda -p database {word list from many files via pipe}

With one call, joda can be feeded with words from hundreds or thousands of files. A Perl or Python script (or something similar) creates the word lists, separated by the chars described above and calls joda. This is the most performant kind of indexing, because joda as a binary executable is very fast with its duties archiving and retrieving. But scripts written in Perl or Python are more flexible for filtering purposes. So a combination of both is most reliable.

Alternativly you can use the next function, where directory scanning is done by joda, calling a filter program for each file:

Indexing multiple files from a directory tree:
joda -a database filepath filepattern [datestamp]

Examples:

In most cases the "-p" function above is recommended because it needs only one auxiliary system call (the joda call) in total and not one call for every file to be archived. On the other hand, the "-a" call needs only a very simple filter script without any other functionality.

See above (-s) for the structure of the word list.

Erase one file via filter program:
joda -d database fileToDelete id {word list from file via filter prog}

Example:

Erase one file via word list:
joda -e database wordList id {word list from file}

Example:

Merge two databases into one or optimize a database:
joda -m [-wordcheck] [-filecheck] [-verbose] database sourcedb [minimalDate]

Example:

Merge can be used for the optimization of a database. For this purpose, it is sufficient, to create a copy (or softlink) of the source database config file as target config file. Now merge the existing database into the new (empty) one. The result is a perfect optimized copy of the source database, because now all equal words are (internally) pooled in one cluster. This will minimize disk seeks, therefore improves retrieving speed and saves disk space. Strongly recommended at least for for completed databases (like archives).

Optimize a database:
joda -opt [-wordcheck] [-filecheck] [-verbose] database [minimalDate]

Example:

This is just an abbreviation for "merge". After the processing the optimized database has the same name as the original one. During the processing a temp file name is used.

Retrieving functions:
joda -q   database query [from] [until] [fFilter] [maxHits] [sortOrder] [info]
joda -qu database query [from] [until] [fFilter] [maxHits] [sortOrder] [info]

With -q(u) joda retrieves all files/records with matched the given query. The letter "u" means that the query is formatted in UTF-8. Otherwise the query has to be in the same ISO-8859-XX format like the archived words. If "u" is used, the value "charsettable" in the databases config file has to be set to one of the "8859_X.iso translation tables belonging to the joda distribution.

The first two lines of jodas respone are always:

The format of the hits depends on the value of "fileref" in the database configuration file. Working with filenames (a *.ref file exists), joda answers:

Without file ref joda will answer per hit:

Important: " · " chars shown above are TABS in reality, this means \t (character #9)!

Query examples:


joda -x   database query [from] [until] [fFilter] [bFilter] [maxHits] [sortOrder]
joda -xu database query [from] [until] [fFilter] [bFilter] [maxHits] [sortOrder]

The difference between queries using "-q" and those using "-x" is only the handling of the bit filter. While it is in -q a single value which has to match exactly, its use in -x is more sophisticated.

[lydon documentation starts here (to be written)]

SourceForge.net Logo