DBM is a simple UNIX database format. It uses a key-value storage and hashing for fast retrieval of the data by key.
Questions tagged [dbm]
98 questions
1
vote
1 answer
android - detect low network signal, which value to rely on
I want to detect a situation where the user is somewhere with low reception (low network signal) for an amount of time (5 minutes for example), and I am wondering what value to rely on.
What I have now is:
public class RadiationTest {
…

Ofek Agmon
- 5,040
- 14
- 57
- 101
1
vote
1 answer
How to properly tie a hash with DBM::Deep to avoid memory leaks?
I am doing a graph analysis of some very large data and I need to store all the scores for a particular set of graph edges. Given the size of the data, I need to write the information to disk and I'm trying to use a tied hash with DBM::Deep. Here is…

SES
- 850
- 1
- 9
- 21
1
vote
2 answers
Ruby connection closed (DRb::DRbConnError)
I am experiencing a really weird behaviour with Ruby DRb or maybe the problem is dbm. I am using the dbm database with a server, and a client that makes the requests via DRb.
Here's the method with the problem (the database connection is ok) and it…

dabadaba
- 9,064
- 21
- 85
- 155
1
vote
1 answer
Apache Rewrite map fails to process lines in map after certain point
We have the following rewrite map setup in our apache config:
RewriteEngine on
RewriteMap modernmap txt:/etc/apache2/maps/salon/www.modernmap.com.txt
RewriteCond ${modernmap:$1|NOT_FOUND} !NOT_FOUND
RewriteRule ^(.+) ${modernmap:$1} [R=301,L]
The…

user3745855
- 83
- 1
- 6
1
vote
1 answer
get SignalStrength in dbm
I would like to show the the signal strength in dbm. But with my code i always become the result -1. But when i see the signal strength in the settings it's around -81..
Can you find a mistake? thank you!
public class MainActivity extends Activity…

user3379235
- 29
- 1
- 6
1
vote
1 answer
Reading perl flat file db with php
I have an old flat file perl db that's part of an eCommerce site I want to migrate to a new php application.
Is it possible to read with php the "table" files have no file extension and seem not be just csv's or similar?

Louise McMahon
- 1,655
- 3
- 15
- 21
1
vote
4 answers
How do I access random element in a Perl DBM hash?
I have a Perl DBM hash containing a list of URLs that I want to pick randomly from to load balance spidering sites. As a result I want to pick a key at random, or select the nth element (so I can randomise n).
I'm aware this goes against the…

Paul
- 1,874
- 1
- 19
- 26
1
vote
1 answer
Why when using DBM with Ruby, db[1] = 2 is ok, but print db[1] will give error?
On Ruby, when using DBM
require "dbm"
db = DBM.open("somedata")
db[1] = 2 # ok
p db[1] # gives error
does anyone know db[1] = 2 is ok, but printing out db[1] will give error?
If it requires db["1"] to be valid, then how come it doesn't apply…

nonopolarity
- 146,324
- 131
- 460
- 740
1
vote
1 answer
sqlite with Python is unreasonably slow compared to anydbm
My goal is to create a database of MD5 hashes, and then check another list of hashes against it to see if they exist in the database.
I have a working solution using anydbm, which if you are unfamiliar works exactly like a dictionary in python, but…

user1442389
- 83
- 1
- 6
1
vote
3 answers
moving a perl script/dbm to a new server, and shifting out of dbm?
I've been tasked with mirroring a site onto a new server. The old site has a few Perl scripts that, as far as I can see internally (i know nothing about Perl, though I have a pretty good understanding of coding generally, and specifically…

dama_do_bling
- 244
- 5
- 17
1
vote
1 answer
How to empty DBM file in Python efficiently?
There is a command in DBM module to delete the value stored at a key.
del d[key] # delete data stored at key (raises KeyError # if no such key)
But I cannot even iterate with this command, because the Runtime error occurs.(RuntimeError:…

Sashko Kopyl
- 71
- 1
- 1
- 8
1
vote
1 answer
Tokyo Cabinet and cygwin
I am trying to install Tokyo Cabinet under Windows Cygwin but when I run ./configure I get the following error:
configure: error: regex.h is required

user1845360
- 847
- 2
- 12
- 29
1
vote
1 answer
DBM::Deep not working with perl hash reference
I am using a DBM::Deep hash object like so:
my $dbm = DBM::Deep->new(
file => "dbm.db",
locking => 1,
autoflush => 1,
type => "DBM::Deep->TYPE_HASH",
);
#code..
$dbm = $hash_reference;
However,…

srchulo
- 5,143
- 4
- 43
- 72
1
vote
1 answer
DBM::Deep unexplained errors
So I am using DBM::Deep to share data between different forked processes. I set up my DBM::Deep object like this:
my $todo = DBM::Deep->new(
file => "urls.db",
locking => 1,
autoflush => 1,
type =>…

srchulo
- 5,143
- 4
- 43
- 72
1
vote
3 answers
Ideal string length for DBM database?
When using a DBM database (e.g. Berkeley or GDBM), is it better to store data using fewer long strings or more short strings? I can easily structure my data either way. I'm looking for 'better' in the performance sense, but I'm interested in other…
dhowland