dbTalk Databases Forums  

No queue support with the Sleepycat::Db Perl interface?

comp.databases.berkeley-db comp.databases.berkeley-db


Discuss No queue support with the Sleepycat::Db Perl interface? in the comp.databases.berkeley-db forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Kim Scheibel
 
Posts: n/a

Default No queue support with the Sleepycat::Db Perl interface? - 03-23-2006 , 07:21 PM






I've been unsuccessful in trying to use the queue table type with the
Sleepycat:b interface and I cannot figure out why.

===
use Sleepycat:b;

my $db = new Db();
$db->open(undef, "test.db", undef, Db:B_QUEUE, Db:B_CREATE);

my($k, $v) = ('', 'test value');

$db->put($k, $v, Db:B_APPEND);
===
results in:
Db::_put() -- txnid is not an object reference at (eval 2) line 13,
<DATA> line 345.

(transactions aren't configured, obviously)

No luck _with_ transactions either:
===
use Sleepycat:b;

eval {
my $env = new DbEnv;
$env->open('testenv',
Db:B_CREATE|Db:B_INIT_MPOOL|Db:B_INIT_TXN|Db :B_INIT_LOCK,
0666);

my $db = new Db($env);
$db->open(undef, "test.db", undef, Db:B_QUEUE,
Db:B_CREATE|Db:B_AUTO_COMMIT);

my($k, $v) = ('', 'test value');

my $txn = $env->txn_begin;
$db->put($txn, $k, $v, Db:B_APPEND);
$txn->commit;
};
if($@) {
print $@->what, "\n";
}
===
Db:ut: Invalid argument in test_queue_txn, line 18

I've tried a number of other ways with much the same result. Does
anyone know if queues are just not supported by Sleepycat:b?

/Kim


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.