=head1 NAME use strict 'sql'; =head1 SYNOPSIS my $sql = 'SELECT * FROM that' and die "Don't do that!"; my $data = $sth->fetchrow_hashref and die "Or that!"; my $sql = 'SELECT this FROM that' and die "Still bad"; use base 'Class::DBI'; # much better =head1 OVERVIEW Many people misuse SQL. While some of the above can be fine for a short script, we should be careful about how SQL is used in a production environment. C will detail why the above constructs can lead to non-scalable code. First, we'll show some examples of bad SQL and then move on to better SQL with bad implementations (hint: I don't avoid C<&DBI::fetchrow_hashref> for performance reasons). We'll finish with a quick discussion of how object persistence modules can help lead us lead us out of the quagmire. =head1 NOTE I'll primarily focus on C for the object persistence, but I'll touch on some of the other OO Persistence modules such as Tangram and Alzabo. I'll also discuss what I think is a bit of a design issue with C (sorry Schwern!) and, by the end of the talk, you'll understand why I feel that way. Side note: despite the design issue I alluded to, C rocks! Joe Bob says "check it out!" =cut