federicoceratto / nim-lmdb Goto Github PK
View Code? Open in Web Editor NEWNim LMDB wrapper
License: Other
Nim LMDB wrapper
License: Other
Hi @FedericoCeratto just a heads up, documentation for this package looks weird:
Hi,
Thanks for the library. I'm thinking this will be a big speed-up for my applications, but i'm having trouble making use of it.
I'm not seeing a proc for getting all keys of a named DB, so i'm guessing i need to get the count of key/value pairs using:
let c = txn.cursorOpen(dbi)
let key_count = c.count()
then, get the keys with something like this:
while i <= count:
if i == 1:
key = c.get("", op = FIRST)
else:
key = c.get("", op = NEXT)
echo key
the empty string are to be a wild attempt at stumbling upon the answer via error message, as i don't see an example with anything besides a hard coded string. Also, I don't understand why the cursor needs a key to be specified to move through keys (using FIRST and NEXT) anyways.
when i try to use count()
, it says the DB is not compat. so, i try to add DUPSORT
to the DB and it complains that my flags have changed
. I try to delete and recreate the DB, but i can't find the syntax for adding more than one dbflag when creating a new DB. I'm thinking i need DUPSORT
and CREATE
.
I've been at this longer than i care to admit, so any help is appreciated.
Thanks
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.