DBD-Sprite
view release on metacpan or search on metacpan
attributes.
sprite_dbdir
Path to tables for database. (read-only after "connect")
sprite_dbext
File extension used on table files in the database.
(read-only after "connect")
sprite_dbuser
Current database user. (read-only after "connect")
sprite_field (NEW)
Field delimiter string in use for the database.
Default specified in database configuration file (<dbname>.sdb)
(NEW!) Set to special string 'XML' to store and read tables in XML
format!
sprite_read (NEW)
Field delimiter string in use for inputting the database.
Default = sprite_field
(NEW!) Set to special string 'XML' to tables in XML format!
sprite_write (NEW)
Field delimiter string in use for outputting the database.
Default = sprite_field
(NEW!) Set to special string 'XML' to store tables in XML format!
Great for converting existing (non-binary) tables to XML format.
sprite_xsl (NEW)
Allows specifying of a url to an xsl template to be written to xml
documents (when using the "xml" option). This makes it very easy to
view your tables via M$ Internet Explorer browser!
Example: sprite_xsl => 'http://turnerville.wwol.com/jim/spritexml2html.xsl'
Default is none. Only applies if "sprite_field" is set to "xml"!
sprite_dbfdelim - DEPRECIATED, now use "sprite_field"!
Field delimiter string in use for the database.
sprite_dbrdelim - DEPRECIATED, now use "sprite_record"!
Record delimiter string in use for the database.
sprite_CaseTableNames
By default, table names are case-insensitive (as they are in Oracle(tm)),
to make table names case-sensitive (as in MySql), so that one could
have two separate tables such as "test" and "TEST", set this option
to 1. (read-only after "connect")
sprite_CaseFieldNames (NEW)
By default, field names are case-insensitive (as they are in Oracle(tm)),
to make field names case-sensitive, so that one could have two
separate fields such as "test" and "TEST" in the same table, set
this option to 1. (read-only after "connect")
sprite_Crypt
"0" by defalt. Specifies that encryption is to be used when storing
the data in the flat-file. To use, download "Crypt::CBC", and one
or more of "Crypt::DES", "Crypt::IDEA", or "Crypt::Blowfish". You
can specify using any of the following formats:
sprite_Crypt => 'my key string'
Use Blowfish encryption.
sprite_Crypt => 'DES;my key string'
Use DES encryption.
sprite_Crypt => 'encrypt=CBC;IDEA;my key string'
Use IDEA encription, but read in table as unencrypted, then
write it out encrypted (great for encrypting previously
unencrypted tables).
sprite_Crypt => 'decrypt=CBC;Blowfish;my key string'
use Blowfish encryption, but write out table unencrypted.
This allows one to fetch an encrypted table and write it back
out unencrypted.
sprite_reclimit
Allows user to specify the maximum number of records to be returned
by a single query. Default is "0", which permits an unlimited number.
sprite_StrictCharComp
CHAR fields are always right-padded with spaces to fill out
the field. Old (pre 5.17) Sprite behaviour was to require the
padding be included in literals used for testing equality in
"where" clauses. I discovered that Oracle(tm) and some other databases
do not require this when testing DBIx-Recordset, so Sprite will
automatically right-pad literals when testing for equality.
To disable this and force the old behavior, set this option to 1.
The following are environment variables specifically recognized by Sprite.
SPRITE_HOME
Environment variable specifying a path to search for Sprite
databases (*.sdb) files.
Driver private methods
DBI->data_sources()
The `data_sources' method returns a list of "databases" (.sdb files)
found in the current directory and, if specified, the path in
the SPRITE_HOME environment variable.
$dbh->tables()
This method returns a list of table names specified in the current
database.
Example:
my($dbh) = DBI->connect("DBI:Sprite:mydatabase",'me','mypswd');
my(@list) = $dbh->func('tables');
Other Utilities
makesdb.pl
This utility lets you build new Sprite databases and later add
additional user-spaces to them. Simply cd to the directory where
you wish to create / modify a database, and run. It prompts as
follows:
Database name: Enter a 1-word name for your database.
Database user: Enter a 1-word user-name.
( run in 1.221 second using v1.01-cache-2.11-cpan-39bf76dae61 )