The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

DBIx::ReportBuilder::Search - Extended SearchBuilder

SYNOPSIS

    my $sb = DBIx::ReportBuilder::Search->new(
        Host        => 'localhost',
        Port        => '3306',
        User        => 'root',
        Driver      => 'mysql',
        Database    => 'rt3',
    );
    $sb->SetTable('Queues');
    $sb->GroupBy( FIELD => 'Disabled' );
    my $col1 = $sb->Column( FIELD => 'Disabled' );
    my $col2 = $sb->Column( FIELD => 'Id', FUNCTION => 'SUM' );
    my $col3 = $sb->Column( FIELD => 'Id', FUNCTION => 'COUNT' );
    $sb->UnLimit;
    print join("\t", qw(Disabled SUM(id) COUNT(id))), "\n";
    while (my $row = $sb->Next) {
        print join(
            "\t",
            $row->{$col1}, $row->{$col2}, $row->{$col3}
        ), "\n";
    };

DESCRIPTION

This module implements a subclass of DBIx::SearchBuilder. The main difference is that it defines a default LoadFromHash and NewItem, so is directly usable without needing to subclass it first.

It also implements GroupBy, GroupByCols, Column and an assortment of other utility functions.

SEE ALSO

DBIx::ReportBuilder, DBIx::SearchBuilder

AUTHORS

Autrijus Tang <autrijus@autrijus.org>

COPYRIGHT

Copyright 2003 by Autrijus Tang <autrijus@autrijus.org>.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

See http://www.perl.com/perl/misc/Artistic.html