Tangram::Driver::Pg(3pm) User Contributed Perl Documentation Tangram::Driver::Pg(3pm)NAME
Tangram::Driver::Pg - Orthogonal Object Persistence in PostgreSQL databases
SYNOPSIS
use Tangram;
use Tangram::Driver::Pg;
$schema = Tangram::Driver::Pg->schema( $hashref );
Tangram::Driver::Pg->deploy($schema, $dbh);
$storage = Tangram::Driver::Pg->connect( $schema,
$data_source, $username, $password );
$storage->disconnect();
Tangram::Driver::Pg->retreat($schema, $dbh);
DESCRIPTION
This is the entry point in the Pg-specific object-relational persistence backend.
This module performs the following:
METHODS
This backend does not add any methods; for a description of available methods, see Tangram::Relational.
ERRATA
Tangram::Type::Dump::Storable objects are first encoded with MIME::Base64, because Tangram does not currently have an easy mechanism for
calling "DBI->bind_param()" at the appropriate time to flag the column as binary.
Tangram::Type::Dump::Perl objects are stored as "BYTEA" columns, which as of DBD::Pg 1.31, also do not get correctly escaped by the DBD
driver. This also affects the (as-yet not fully functional) Tangram::Type::Dump::YAML back-end, which might put "" characters into a YAML
document.
It is recommended to use the "storable" type with Tangram::Type::Dump::Any for this reason.
perl v5.8.8 2006-03-29 Tangram::Driver::Pg(3pm)
Check Out this Related Man Page
Tangram::Type::Dump(3pm) User Contributed Perl Documentation Tangram::Type::Dump(3pm)NAME
Tangram::Type::Dump - Handy functions for Pixie-like dumping of data
SYNOPSIS
use Tangram::Type::Dump qw(flatten unflatten UNflatten nuke);
use YAML qw(freeze thaw); # for instance
my $frozen = freeze flatten($storage, $structure);
# optional - remove circular references from flattened
# structure so that it is freed up properly.
nuke $frozen;
# save frozen somewhere...
# restore, but don't load objects straight away
my $reconstituted = unflatten($storage, thaw $frozen);
# restore, loading objects immediately
my $original = UNflatten($storage, $frozen);
# Alternative, quickly marshall a structure for saving
my $structure;
flatten($storage, $structure);
# ... do something with it ...
# restore to former glory; note that Tangram's cache will
# prevent unnecessary DB access.
unflatten($storage, $structure);
DESCRIPTION
This module contains functions for traversing data structures which are not Tangram-registered objects, and replacing all the Tangram
objects found with `Mementos'.
When a similar data structure is fed back into the reversal function, the mementos are filled with on-demand references to the real
objects.
All these functions operate in place for maximum efficiency.
FUNCTIONS
flatten($storage, $structure)
Traverses the structure $structure, and replaces all the known (ie, already inserted) Tangram objects with references to them
unflatten($storage, $structure)
Performs the logical opposite of flatten, but only insofar as a `normal' user is concerned. `Normal' users, of course, don't care that
the data structure is being loaded from the database as they use it :).
BUGS
Should this module just be an extension to Tangram::Storage ?
AUTHOR
Sam Vilain, samv@cpan.org. All rights reserved. This code is free software; you can use and/or modify it under the same terms as Perl
itself.
perl v5.8.8 2006-03-29 Tangram::Type::Dump(3pm)
Hi
I've a file like so:
Now, I want to read my file and take ex. the Media ID and the Type for each groups of Media (Media1,Media2,...,Media(n):
cat /tmp/file|\
while read FILE
do
while $(FILE|cut -d: -f1)=Media$i
do
#here will be some test, ex:
#if Media ID < 23
... (4 Replies)
I looking for someone who can help me port a Linux Driver to a OpenBSD( OS X ) Unix Driver. The driver is for a Logic Controls LD9000 USB Customer Display. The currently don't have a driver for the mac operating system, but they do however have one for the Linux OS.
So, I am just trying to... (8 Replies)
I just bought a Lexmark PRO901 printer, for I was told that it was debian compliant.
Upon unpacking I saw mention of Ubuntu.
I thought of returning it but found a site that had
Printer Driver with JRE for 64-bit Debian Package Manager based Distros
What I downloaded was ... (1 Reply)
I have 3 files, data file,schema file and a threshold file.
Data file contains data in which columns are distributed according to schema file. This data file doesn't contain any headers.
Three continuous columns in the data file represent single variable in schema file.
first column represent... (1 Reply)