NAME
MySQL::GUI::connector::dbase - Perl extension to make the db stuff a little less painless.
SYNOPSIS
use strict;
use MySQL::GUI::connector::dbase;
# to do db transactions
my $dbo = new MySQL::GUI::connector::dbase;
my $dbh = $dbo->handle;
my $sth = $dbh->prepare("select * from something");
my $STH = $dbo->ready("select * from something"); # shortcut. ;)
# the dbase.pm uses the .my.cnf to be able to connect pretty like that...
# you can override it. After the $dbo is connected this will
# not do anything! Note that there is no connect function.
$dbo->disconnect;
$dbo->set_db( "cool_db" );
$dbo->set_host( "localhost" );
$dbo->set_user( "jettero" );
$dbo->set_pass( "S3crET" );
my $sth =
$dbo->ready("select * from cool_table"); # this connects automajikcally;
# so does the $dbo->handle function.
$dbo->trace( 1 ); # will do what you expect before/after connect,
# and will persist even after a $dbo->disconnect.
# to read a .my.cnf
my $temp = new MySQL::GUI::connector::dbase;
my ($u, $p, $d, $h) = $temp->get_defaults;
undef $temp;
AUTHOR
Jettero Heller <jettero@voltar.org>
SEE ALSO
perl(1), MySQL::GUI(3), MySQL::GUI::connector(3), MySQL::GUI::connector::dbase(3), MySQL::GUI::connection(3).