Re: MySQL queries in a relational database
Darren Duncan <[email protected]> Wed, 30 Mar 2011 11:14:24 -0700
| Newsgroups | gmane.comp.db.mysql.perl |
|---|---|
| Message-ID | <[email protected]> |
francesca casalino wrote: > I am now having trouble with generating a query in Perl DBI to take data > from this database and insert it into another table in MySQL; I am still > just at the start in learning both MySQL and Perl, and sorry if this is a > simple question again, but I have been stuck on this for a while now…if you > have any advice on how to tackle this please let me know. I don't know if you're already doing this, but you may be able to do your SELECT and INSERT as a single SQL statement, which is simpler than pulling your data out to Perl and pushing it in again. insert into mytbl (mycol1, mycol2) select mycol1, mycol2 ... <ordinary select statement continues> -- Darren Duncan -- MySQL Perl Mailing List For list archives: http://lists.mysql.com/perl To unsubscribe: http://lists.mysql.com/[email protected]