Hi, Do you know a database written purely in Perl with DBI interface? Or what can be used if there is no MySql or Postgresql installed and I want to use Perl only?
Thank you.
Ok, I just wanted something that can be used with Catalyst.
Hi, Do you know a database written purely in Perl with DBI interface? Or what can be used if there is no MySql or Postgresql installed and I want to use Perl only?
Thank you.
Ok, I just wanted something that can be used with Catalyst.
That depends greatly on what you consider "database".
If you just want something to store your data, there's a number of Perl databases avialable. Some are listed here: http://www.perl.com/pub/a/2004/09/12/embedded.html
Tie::File
Berkley DB
SQLite
Please note that despite "SQLite is written in C" comments I saw here, the article explicitly states:
Conveniently, the DBI-driver for SQLite, DBD::SQLite, already contains the database engine itself as part of the module - so installing this module is all that is required to be able to use SQLite from Perl.
However, NONE of the above is a real database engine, supporting transactions etc..., although some allow SQL-like query language access
I'm not aware of any real database engines implemented in Perl.
Perl rule 34:
If you can imagine it, there's a DBD module for it ;)
I believe DBD::CSV is a simple DBD implementation that uses Text::CSV to persist data to CSV files.
AFAIK there is no database in pure perl that is relational, it's not really economical; you might look in ACME on CPAN.
Essentially you have two choices: a pure perl module that provides a DBD package that wraps around, for example .txt, .csv, or .xml files.
If there is none, you could also implement a BDB/DBM style system of your own using pure perl, much like Ken Thompson did in C with DBM. It however, wouldn't be as complex as having SQL based relational database.
If you expect to use SQL, use an SQL based database.