DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 

db truncate

API Ref

db truncate
	[-txn txnid]

Description(db truncate)

Empties the database, discarding all records it contains.

The options are as follows:

-txn txnid
If the operation is part of an application-specified transaction, the txnid parameter is a transaction handle returned from env txn. If no transaction handle is specified, but the operation occurs in a transactional database, the operation will be implicitly transaction protected.

The db truncate command returns the number of records discarded from the database on success.

In the case of error, a Tcl error is thrown.


APIRef

Copyright (c) 1996-2005 Sleepycat Software, Inc. - All rights reserved.