Database creation
Russell Matbouli
russell-belfast-pm at futureless.org
Sat Mar 30 09:00:53 CST 2002
On Sat, Mar 30, 2002 at 01:30:45PM +0000, Stray Toaster wrote:
> On Sat, Mar 30, 2002 at 01:17:43PM +0000, Russell Matbouli wrote:
> > According to the DBI FAQ, it isn't possible to create a database using
^^^^^^^^^^^^^^^^^
> > push a CREATE statement into a call to the 'mysql' binary?
^^^^^^^^^^^^^^^^
I think I said the wrong thing here. I mean to create a database. Can
you do this in SQL? I've only ever done it with mysqladmin before. At
least, as far as I can remember that's what I used...
> my $query = qq{ CREATE blah etc etc };
>
> $dbh->execute($query)
^^^^
How do you get a database handle on a database that doesn't yet exist
though?
> gazooks, when was the last time I had a query in a script? Or a query in
> a module come to that? Long life Class::DBI!
Is there a Class::DBI way to do it? That's what I'm using :)
--
Russell Matbouli |
russell at futureless.org | What if it does not work?
PGP KeyID: 0x3CA84CF4 |
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 232 bytes
Desc: not available
Url : http://mail.pm.org/archives/belfast-pm/attachments/20020330/68b3bdbe/attachment.bin
More information about the Belfast-pm
mailing list