Win has asked for the wisdom of the Perl Monks concerning the following question:
I want to run two $sql assigned create table statements and run them one after the other, adding tables to the same database. My program creates the first table but not the second. Any suggestions why?
my $sql = qq{ CREATE TABLE Table_A ( #SQL goes in here )}; $dbh->do($sql); $dbh->disconnect(); if ($table_name = $Table_4){ print "hereb\n"; my $sql = qq{ CREATE TABLE Second_table ( + #SQL statement goes in here )}; my $dbh->do($sql); $dbh->disconnect(); }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Table creation
by edan (Curate) on Nov 24, 2003 at 13:39 UTC | |
|
Re: Table creation
by moxliukas (Curate) on Nov 24, 2003 at 13:17 UTC | |
by Win (Novice) on Nov 24, 2003 at 13:33 UTC | |
by Roger (Parson) on Nov 25, 2003 at 01:00 UTC |