Andrew Brosnan wrote:

On 10/18/02 at 2:10 PM, [EMAIL PROTECTED] (Jeff Zucker) wrote:
> ...
> Yes Jeff, I thought the same thing. But that won't work for me in this
> case. I need to be able to create a new db without assuming that there
> is an existing one (or at least I might not know what it is).

Did you try it? This works for me (notice there's no database specified in the connection):

my $dbh = DBI->connect("dbi:mysql:");
$dbh->do("CREATE DATABASE $new_db");
$dbh->do("USE $new_db");
# commands to create and query tables in $new_db

--
Jeff



Reply via email to