SQL::OOP::Update
my $update = SQL::OOP::Update->new; # set clause by plain text $update->set( $update->ARG_TABLE => 'some_table', $update->ARG_DATASET => 'a = b, c = d', $update->ARG_WHERE => 'a = c', ); # reset clauses using objects $update->set( $select->ARG_TABLE => SQL::OOP::ID->new('some_table'), $update->ARG_DATASET => SQL::OOP::Dataset->new(%data), $select->ARG_WHERE => $where->cmp('=', "some_fileld", 'value') ); my $sql = $update->to_string; my @bind = $update->bind;
SQL::OOP::Select class represents Select commands.
Constructor. It takes arguments in hash. The Hash keys are provided by following methods. They can call either class method or instance method.
ARG_TABLE ARG_DATASET ARG_FROM ARG_WHERE
This method resets the clause data. It takes same argument as constructor.
argument key for TABLE(=1)
argument key for DATASET(=2)
argument key for FROM clause(=3)
argument key for WHERE clause(=4)
Sugama Keita, <sugama@jamadam.com>
Copyright (C) 2011 by Sugama Keita.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install SQL::OOP, copy and paste the appropriate command in to your terminal.
cpanm
cpanm SQL::OOP
CPAN shell
perl -MCPAN -e shell install SQL::OOP
For more information on module installation, please visit the detailed CPAN module installation guide.