[geeks] Solaris 10 install size
Charles Shannon Hendrix
shannon at widomaker.com
Mon Jul 24 12:24:14 CDT 2006
Sun, 23 Jul 2006 @ 13:21 -0400, Phil Stracchino said:
> Charles Shannon Hendrix wrote:
> > Why are you looking at classes?
> >
> > There are several ways to do this.
> >
> > It occurs to me the simplest way would be to avoid any big classes, and
> > just bash strings:
> >
> > $basesql = "insert into <database> values (%s, %s, %s,...)";
> > while (loop through data structure)
> > {
> > $sql = sprintf($basesql,$var1,$var2,$var3,...);
> > $dbh->do($sql);
> > }
> >
> > There are different and faster ways like using bound variable statements
> > and that sort of thing, but that's up to you and your exact needs. It
> > all boils down to a simple loop and string bashing.
>
> Frankly, the obvious way is to use DBI and DBD::MySQL.
Um, the example I gave *DOES* use DBI and DBD...
I just didn't bother with the initialization, but $dbh above is a DBI
handle.
I have used Perl for years, and sometimes forget to put in details, and
assumed Bill knew he'd need to use DBI.
--
shannon "AT" widomaker.com -- ["Secrecy is the beginning of tyranny." --
Unknown]
More information about the geeks
mailing list