Perhaps apply the retrieve method to the $db object?
if ($db->docExists('12345')) { print "hello\n"; $doc = $db->retrieve('12345'); } else { $doc = $db->newDoc('12345', undef, {'foo'=>'bar'})->create; }
In reply to Re^3: Retrieving content from couchdb using CouchDB::Client
by GotToBTru
in thread Retrieving content from couchdb using CouchDB::Client
by shivam99aa
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |