CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Sep 2005
    Posts
    2

    Unhappy Berkeley DB's Queue DB problem

    Hi all,
    In Berkeley DB, How can I store and retrieve records in queue type in Berkeley DB?.
    If I want to use dbp->put(dbp, NULL, &key, &data, DB_APPEND); API to append an element to the queue type what is the value I should pass to the key field?

    And how can I retrieve the storedrecords?

    Any examples availabe?

    My MSN & Mail: [email protected]

  2. #2
    Join Date
    Jun 2005
    Posts
    1,255

    Re: Berkeley DB's Queue DB problem

    The DB->put() method stores key/data pairs in the database.

    If the database supports duplicates, then the key can be the same for different DB->put().

    In the key, I would put "queue" or a record number.

    See exemples at:

    http://www.sleepycat.com/docs/ref/am_conf/logrec.html
    http://pybsddb.sourceforge.net/ref/simple_tut/put.html
    http://www.datalab.uci.edu/people/xge/mlword/node9.html

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured