Not logged in

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:more documentation fixes
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:f0f2461630a3d59e26c5f9f0031ce7d992d069cb
User & Date: brandon 2013-11-17 17:01:46
Context
2013-11-17
17:01
bump version number again check-in: 7eacae8f77 user: brandon tags: trunk
17:01
more documentation fixes check-in: f0f2461630 user: brandon tags: trunk
16:48
update online documentation check-in: 3d0e1f4fd2 user: brandon tags: trunk
Changes

Changes to doc/zeptodb.texi.

79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95




96
97
98
99
100
101
102
103
104
105
...
114
115
116
117
118
119
120




121
122
123
124
125
126
127
...
242
243
244
245
246
247
248








249
250
251
252
253
254
255
@end detailmenu
@end menu

@node Introduction, Commands, Top, Top
@chapter Introduction

zeptodb is a small collection of relatively tiny command-line tools for
interacting with DBM databases.  For the uninitiated, DBM databases are
flat (non-relational) a databases; in other words, they are persistent
key-value hash tables. Typically they are created via a library for C,
Python, Perl, etc. These tools fill in a gap by providing useful
command-line tools. Some DBM libraries come with really basic binaries
for manipulating the databases, but they are not designed to be very
flexible or useful in the real world.

These tools may be helpful in scripts, for example, when persistant
data storage is needed but when a full database would be overkill.




They may also be useful if, for whatever reason, one would like to
manipulate, via the command-line or scripts, DBM databases created by
other programs.

@menu
* Tutorial::
* Back-ends::
@end menu

@node  Tutorial, Back-ends, Introduction, Introduction
................................................................................
their formats.

First, you create a new database with @command{zdbc}:

@example
$ zdbc foo.db
@end example





You can customize the creation of a database in two ways.  The first is
by specifying the number of @dfn{buckets} that comprise the database,
specified via the @option{-b}/@option{--num-buckets} option.  A DBM
database can be imagined as a series of buckets.  When a new item is
added, an algorithm determines which bucket it belongs in based on its
key.  Likewise, the same algorithm will be used in determining the
................................................................................
$ zdbr foo.db <<EOF
> Brandon
> Joe
> EOF
$ zdbf -a -d'|' foo.db
Mary|baz@@example.com
@end example









@node  Back-ends,  , Tutorial, Introduction
@section Back-ends

By default, zeptodb uses the @uref{http://www.gnu.org/software/gdb,
GNU dbm} (GDBM) library to create and manipulate the DBM databases.
Alternatively, you may choose to use the







|
|
|
|
|
|
|

|
|
>
>
>
>
|
|
<







 







>
>
>
>







 







>
>
>
>
>
>
>
>







79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101

102
103
104
105
106
107
108
...
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
...
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
@end detailmenu
@end menu

@node Introduction, Commands, Top, Top
@chapter Introduction

zeptodb is a small collection of relatively tiny command-line tools for
interacting with @dfn{DBM databases}.  For the uninitiated, DBM
databases are flat (non-relational) a databases; in other words, they
are persistent key-value hash tables. Typically they are created via a
library for C, Python, Perl, etc. These tools fill in a gap by providing
useful command-line tools. Some DBM libraries come with really basic
binaries for manipulating the databases, but they are not designed to be
very flexible or useful in the real world.

These tools may be helpful in scripts, for example, when persistant data
storage is needed but when a full database would be overkill.  DBM
databases offer a constant look-up time for any record in them, as
opposed to, say, searching through a text file, which scales linearly
with the number of lines in the file.  Thus, scripts requiring fast data
look-up would benefit greatly from them.  These commands may also be
useful if, for whatever reason, one would like to manipulate, via the
command-line or scripts, DBM databases created by other programs.


@menu
* Tutorial::
* Back-ends::
@end menu

@node  Tutorial, Back-ends, Introduction, Introduction
................................................................................
their formats.

First, you create a new database with @command{zdbc}:

@example
$ zdbc foo.db
@end example

Note: the following two paragraphs contain technical information that is
only necessary if you will be creating large databases with many
records.  If that is not the case, you may safely skip them.

You can customize the creation of a database in two ways.  The first is
by specifying the number of @dfn{buckets} that comprise the database,
specified via the @option{-b}/@option{--num-buckets} option.  A DBM
database can be imagined as a series of buckets.  When a new item is
added, an algorithm determines which bucket it belongs in based on its
key.  Likewise, the same algorithm will be used in determining the
................................................................................
$ zdbr foo.db <<EOF
> Brandon
> Joe
> EOF
$ zdbf -a -d'|' foo.db
Mary|baz@@example.com
@end example

Of course, these examples are not realistic.  Rather than using the
programs from the command-line, you are more likely to use them in
scripts.  For example, one script might save data to a database while
another script reads from that data.  You can even build up relations
between multiple databases, storing the keys of one database as values
in another database, allowing quite complex, but always fast, look-ups
within your scripts.

@node  Back-ends,  , Tutorial, Introduction
@section Back-ends

By default, zeptodb uses the @uref{http://www.gnu.org/software/gdb,
GNU dbm} (GDBM) library to create and manipulate the DBM databases.
Alternatively, you may choose to use the