Solved

Storage format / engine for my database

Posted on 2012-12-31
13
356 Views
Last Modified: 2013-01-08
I have a data set with ~7 million 32-character strings.  I am trying to find the most efficient storage for it.

It needs to be encrypted.
It needs fast searching.
It needs to be stand-alone.
It needs to be as compact as possible for online distribution.

I have tried Absolute Database but the resulting data file is about 800K.
I tried mOrmot SQLite3 and the data file is about 400K.
I tried a simple in-memory string list but it gobbles up about 450K of RAM.

What are my options?
0
Comment
Question by:DSOM
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 7
  • 3
  • 2
  • +1
13 Comments
 
LVL 37

Expert Comment

by:Geert Gruwez
ID: 38734116
have you got any realistic numbers of what to expect ?

32x7000000 chars = 224000000 bytes (or 213 Mb)

400K / 213Mb is a factor of 1/532,
so thats a very good compression factor by the look of it

it looks like you already have what you look for

or is there an other problem ?
0
 

Author Comment

by:DSOM
ID: 38734141
I don't know what to expect or what my options are which is why I asked.

I am hoping there might be something more suitable that I haven't found yet.

If it is indeed the best option that is fine too, I just need to know it.
0
 
LVL 17

Expert Comment

by:Gerald Connolly
ID: 38734318
Well, i guess it depends on what you are really doing with this.

213MBytes  (NB "b" = bits, "B" = Bytes) is a tiny database and you would have to go back probably 10 years to find a memory stick it couldnt fit on!
Even on 4Mb broadband it will only take 5 minutes or so to download.

Why does it need to be compressed? It will just make it slower to access.
0
U.S. Department of Agriculture and Acronis Access

With the new era of mobile computing, smartphones and tablets, wireless communications and cloud services, the USDA sought to take advantage of a mobilized workforce and the blurring lines between personal and corporate computing resources.

 

Author Comment

by:DSOM
ID: 38734415
It only needs to be compressed during distribution/installation.  It is expanded on the end-users' computer.

Ugh, I just realized what I did.  Posting when tired and not braining properly.

It doesn't look like I can edit my original question.  Should have been:

I have tried Absolute Database but the resulting data file is about 800MB.
I tried mOrmot SQLite3 and the data file is about 400MB.
I tried a simple in-memory string list but it gobbles up about 450MB of RAM.
0
 
LVL 27

Expert Comment

by:Sinisa Vuk
ID: 38734962
How does your strings look like? Is it something like hex numbers? or just random characters.
0
 
LVL 17

Expert Comment

by:Gerald Connolly
ID: 38735118
why is 800MB a problem?

How are you distributing this db and how often are there updates?
0
 

Author Comment

by:DSOM
ID: 38735444
It is too big.  Customers still on slow connections or even dialup have problems with it.  The download installer at almost 1GB is using up almost 5TB a month in bandwidth.  That is just for the initial distribution/installation.

It is being distributed via my website.  Updates are daily but just incrementally so that isn't a big problem.
0
 
LVL 37

Expert Comment

by:Geert Gruwez
ID: 38738339
have you tried putting the strings in a text file and zipping it ?
zip is very good at text compression
0
 

Author Comment

by:DSOM
ID: 38738506
I tried using a compressed string list.  But it takes up too much RAM when loaded.  From my original question "I tried a simple in-memory string list but it gobbles up about 450MB of RAM."
0
 

Accepted Solution

by:
DSOM earned 0 total points
ID: 38738510
I am trying SynSQLite3 right now and it looks promising.  About 500MB on disk and almost zero memory footprint.  That database will compress down to about 300MB for distribution which is a huge improvement over almost 1GB.
0
 
LVL 37

Expert Comment

by:Geert Gruwez
ID: 38739325
lol, i wasn't meaning for you to load as a stringlist
>> my idea was:
put all your text in a file.txt
> zip this file.txt

when you start your app or appinstaller:
> unzip the file
> load it into a database in the local environment

the local environment could be a company which hosts an enterprise database like sql server, oracle, etc ...
that way you can have 1 dictionary (at least i think it's a dictionary)
for all pc's in 1 local environment and you'd only have to do the upload once
and set the connection string on the others

>> i know it's a differrent ball game like this
0
 

Author Comment

by:DSOM
ID: 38739426
When I do an incremental update it is a zipped text file that is imported.  However the original distribution contains the full current database.  The end-user won't have a database server aside from the one I run which they access over the Internet.  This isn't for enterprise customers, it's average home users.

The database on the customer's home computer is a stand-alone SQL database.
0
 

Author Closing Comment

by:DSOM
ID: 38754116
This has ended up being the best option
0

Featured Post

U.S. Department of Agriculture and Acronis Access

With the new era of mobile computing, smartphones and tablets, wireless communications and cloud services, the USDA sought to take advantage of a mobilized workforce and the blurring lines between personal and corporate computing resources.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Create your own, high-performance VM backup appliance by installing NAKIVO Backup & Replication directly onto a Synology NAS!
The article will include the best Data Recovery Tools along with their Features, Capabilities, and their Download Links. Hope you’ll enjoy it and will choose the one as required by you.
This tutorial will walk an individual through the process of installing the necessary services and then configuring a Windows Server 2012 system as an iSCSI target. To install the necessary roles, go to Server Manager, and select Add Roles and Featu…
This Micro Tutorial will teach you how to reformat your flash drive. Sometimes your flash drive may have issues carrying files so this will completely restore it to manufacturing settings. Make sure to backup all files before reformatting. This w…

737 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question