A way to go about it: start with DBD::ODBC (really DBI as BUU suggested) and CGI. If your app is as simple as you suggest, you can probably stop there. Here is some loose pseudo-code for it. You'll have to do a great deal of reading or get some more help, perhaps point by point after reading bits you can absorb, to complete it and make it safe.
use warnings; no warnings 'uninitialized';
use strict;
use CGI qw(:standard);
use DBI;
my $data_source = 'whatever';
my $username = 'whoever';
my $auth = 'whichever';
my %attr = ();
print
header(),
start_html(-title => "Search poems"),
start_form(),
textfield(-name => 'q');
eval {
my $dbh = DBI->connect($data_source, $username, $auth, \%attr);
if ( param('q') ) {
my $sth = $dbh->prepare(<<"");
SELECT * FROM whatever WHERE this MATCHES ?
$sth->execute( param('q') );
while ( my $row = $sth->fetchrow_hashref ) {
# format and print the results
}
# OR mention you couldn't find anything
}
};
print h3("Couldn't execute querry! $@") if $@;
print
end_form(),
end_html();
|