
DBIx::Roles::SQLAbstract - Exports SQL commands insert,
select etc as methods.

The role exports SQL commands insert,
select,
update,
delete after SQL::Abstract fashion.
See SQL::Abstract for syntax of these methods.

use DBIx::Roles qw(SQLAbstract);
my $dbh = DBI-> connect(
"dbi:Pg:dbname=template1",
"postgres",
"password",
);
$dbh-> select( $table, \@fields, \%where, \@order);
$dbh-> insert( $table, \%fieldvals || \@values);
$dbh-> update( $table, \%fieldvals, \%where);
$dbh-> delete( $table, \%where);

Mostly all of the text below is copy-pasted from SQL::Abstract (c) 2001-2005 Nathan Wiger
This is the simplest function. You simply give it a table name and either an arrayref of values or hashref of field/value pairs.
This takes a table, arrayref of fields (or '*'), optional hashref WHERE clause, and optional arrayref order by.
Prepares and executes a query, and returns the statement handle, if successful.
This takes a table, hashref of field/value pairs, and an optional hashref WHERE clause.
This takes a table name and optional hashref WHERE clause.


Copyright (c) 2005 catpipe Systems ApS. All rights reserved.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

Dmitry Karasik <dk@catpipe.net>