From: Matt Davies | Postgresql List <matt-postgresql@mattdavies.net>
Cc: pgsql-performance@postgresql.org
Subject: Re: Storing Digital Video
Date: Tue, 31 Jan 2006 17:51:18 -0700
Message-ID: <43E00606.6030406@mattdavies.net> (raw)
In-Reply-To: <3cf983d0601311632t4a2f068au1f958746c2b092a7@mail.gmail.com>
References: <3cf983d0601311632t4a2f068au1f958746c2b092a7@mail.gmail.com>
Rodrigo Madera wrote:
>I am concerned with performance issues involving the storage of DV on
>a database.
>
>I though of some options, which would be the most advised for speed?
>
>1) Pack N frames inside a "container" and store the container to the db.
>2) Store each frame in a separate record in the table "frames".
>3) (type something here)
>
>Thanks for the help,
>
>
>
My experience has been that this is a very bad idea. Many people want to
store all sorts of data in a database such as email messages, pictures,
etc... The idea of a relational database is to perform queries against
data. If you are needing to just store data then store it on a disk and
use the database as the indexer of the data.
Keep in mind the larger the database the slower some operations become.
Unless you are operating on the frame data (which you either store as
blobs or hex-encoded data) I'd recommend you store the data on a hard
drive and let the database store meta data about the video such as path
information, run time, author, etc...
We do this on an application storing close to a million images and the
performance is impressive.
1. we don't have to do any sort of data manipulation storing the
data in or retrieving the data out of the database.
2. our database is compact and extremely fast - it is using the
database for what it was designed for - relational queries.
My $0.02
>Rodrigo
>
>---------------------------(end of broadcast)---------------------------
>TIP 9: In versions below 8.0, the planner will ignore your desire to
> choose an index scan if your joining column's datatypes do not
> match
>
>
>
>
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: matt-postgresql@mattdavies.net
Subject: Re: Storing Digital Video
In-Reply-To: <43E00606.6030406@mattdavies.net>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox