12 our ($VERSION, @ISA, @EXPORT, @EXPORT_OK, %EXPORT_TAGS);
15 @EXPORT = qw(db_connect db_commit www_begin hquote
25 $r->header_out("Cache-Control: no-cache");
30 return pack "H*", $raw;
34 my $dbf = "$ENV{'NJAWAYMSG'}/data/away.db";
35 $dbh = DBI->connect("dbi:SQLite:$dbf",'','',
37 RaiseError=>1, ShowErrorStatement=>1
39 or die "$DBI::errstr ?";
44 my $sth= $dbh->prepare($stmt);
47 if ($row= $sth->fetchrow_hashref()) {
48 die("REFERENTIAL INTEGRITY ERROR\n".
49 "\n$stmt\n". Dumper($row),"\n");
54 nooutput("SELECT * FROM addresses LEFT JOIN config".
55 " USING (emailaddr) WHERE forwardfile IS NULL");
56 nooutput("SELECT * FROM addresses LEFT JOIN texts".
57 " USING (textid) WHERE desc IS NULL");