 Iterate over the database, deleting each record in turn. */
while ((ret = cursorp-&gt;get(cursorp, &amp;key,
               &amp;data, DB_SET)) == 0) {
    cursorp-&gt;del(cursorp, 0);
}

/* Cursors must be closed */
if (cursorp != NULL)
    cursorp-&gt;close(cursorp); 

if (dbp != NULL)
    dbp-&gt;close(dbp, 0);</pre>
    </div>
    <div class="navfooter">
      <hr />
      <table width="100%" summary="Navigation footer">
        <tr>
          <td width="40%" align="left"><a accesskey="p" href="PutEntr