~ubuntu-branches/ubuntu/maverick/evolution-data-server/maverick-proposed

« back to all changes in this revision

Viewing changes to libdb/docs/ref/dumpload/text.html

  • Committer: Bazaar Package Importer
  • Author(s): Didier Roche
  • Date: 2010-05-17 17:02:06 UTC
  • mfrom: (1.10.5 upstream)
  • mto: This revision was merged to the branch mainline in revision 128.
  • Revision ID: james.westby@ubuntu.com-20100517170206-xu1wmjuy40nt2sk0
Tags: upstream-2.30.1
ImportĀ upstreamĀ versionĀ 2.30.1

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
<!--$Id$-->
2
 
<!--Copyright 1997-2002 by Sleepycat Software, Inc.-->
3
 
<!--All rights reserved.-->
4
 
<!--See the file LICENSE for redistribution information.-->
5
 
<html>
6
 
<head>
7
 
<title>Berkeley DB Reference Guide: Loading text into databases</title>
8
 
<meta name="description" content="Berkeley DB: An embedded database programmatic toolkit.">
9
 
<meta name="keywords" content="embedded,database,programmatic,toolkit,b+tree,btree,hash,hashing,transaction,transactions,locking,logging,access method,access methods,java,C,C++">
10
 
</head>
11
 
<body bgcolor=white>
12
 
<a name="2"><!--meow--></a>
13
 
<table width="100%"><tr valign=top>
14
 
<td><h3><dl><dt>Berkeley DB Reference Guide:<dd>Dumping and Reloading</dl></h3></td>
15
 
<td align=right><a href="../../ref/dumpload/format.html"><img src="../../images/prev.gif" alt="Prev"></a><a href="../../reftoc.html"><img src="../../images/ref.gif" alt="Ref"></a><a href="../../ref/install/file.html"><img src="../../images/next.gif" alt="Next"></a>
16
 
</td></tr></table>
17
 
<p>
18
 
<h1 align=center>Loading text into databases</h1>
19
 
<p>The <a href="../../utility/db_load.html">db_load</a> utility can be used to load text into databases.
20
 
The <b>-T</b> option permits nondatabase applications to create
21
 
flat-text files that are then loaded into databases for fast,
22
 
highly-concurrent access.  For example, the following command loads the
23
 
standard UNIX <b>/etc/passwd</b> file into a database, with the login
24
 
name as the key item and the entire password entry as the data item:
25
 
<p><blockquote><pre>awk -F: '{print $1; print $0}' &lt; /etc/passwd |\
26
 
        sed 's/\\/\\\\/g' | db_load -T -t hash passwd.db</pre></blockquote>
27
 
<p>Note that backslash characters naturally occurring in the text are escaped
28
 
to avoid interpretation as escape characters by <a href="../../utility/db_load.html">db_load</a>.
29
 
<table width="100%"><tr><td><br></td><td align=right><a href="../../ref/dumpload/format.html"><img src="../../images/prev.gif" alt="Prev"></a><a href="../../reftoc.html"><img src="../../images/ref.gif" alt="Ref"></a><a href="../../ref/install/file.html"><img src="../../images/next.gif" alt="Next"></a>
30
 
</td></tr></table>
31
 
<p><font size=1><a href="http://www.sleepycat.com">Copyright Sleepycat Software</a></font>
32
 
</body>
33
 
</html>