sdyates has asked for the wisdom of the Perl Monks concerning the following question:
I appreciate your help. I have searched site, but nothing I can find directly relates to what i am trying to do...Perhaps I cannot see the forest for the trees...#====> sql commands my $sth = $dbh->prepare("CREATE TABLE $TableName ($SQLString)") or bla +, bla bla; $sth->execute or bla, bla bla; my $sth = $dbh->prepare("LOAD DATA INFILE $UserFile INTO TABLE $Table +Name") or bla, bla bla; $sth->execute or bla, bla bla; #====> form used to get info... sub generate_form { # Create the form print start_form(-method=>'POST'); print center( table( {-border => 0}, Tr( {-align=>'left', -valign=>'top'}, td("<B>Log File to import:") +, td(filefield(-name=>'LogFile', -default=>'', -size=>50, -maxlength=>50)) ), Tr( {-align=>'left', -valign=>'top'}, td("<B>Database name:"), td( +textfield(-name=>'DBName', -default=>'', -size=>50, -maxlength=>50)) ), Tr( {-align=>'left', -valign=>'top'}, td("<B>Database user:"), td( +textfield(-name=>'DBUser', -default=>'', -size=>50, -maxlength=>50)) ), Tr( {-align=>'left', -valign=>'top'}, td("<B>Database password:"), + td(textfield(-name=>'DBPassword', -default=>'', -size=>50, -maxlength=>50)) ), Tr( {-align=>'left', -valign=>'top'}, td("<B>Table name:"), td(tex +tfield(-name=>'TableName', -default=>'', -size=>50, -maxlength=>50)) ), Tr( {-align=>'center', -valign=>'top'}, td({-colspan=>3}, submit(' +action', 'Add addess'))) ) # end: table() ); # end: center() print end_form(); }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Letting users upload to your CGI scripts (boo)
by boo_radley (Parson) on Aug 22, 2001 at 20:08 UTC | |
by sdyates (Scribe) on Aug 22, 2001 at 20:11 UTC | |
|
Re: Using SQL LOAD DATA INFILE via CGI
by MZSanford (Curate) on Aug 22, 2001 at 19:58 UTC | |
by sdyates (Scribe) on Aug 22, 2001 at 20:21 UTC | |
by MZSanford (Curate) on Aug 22, 2001 at 20:26 UTC | |
|
Re: Using SQL LOAD DATA INFILE via CGI
by ckohl1 (Hermit) on Aug 22, 2001 at 23:27 UTC |