Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

demerphq's scratchpad

by demerphq (Chancellor)
on Jun 07, 2004 at 02:47 UTC ( #361850=scratchpad: print w/ replies, xml ) Need Help??

use Data::Consumer::Dir; use Getopt::Long; my ($db,$user,$name,$procs); Getoptions( 'db=s' => $db, 'user=s' => $user, 'name=s' => $name, 'procs=i' => $procs ) or die "Bad args"; my $pid= $$; fork while $procs-->0 and $pid==$$; my $feed= Data::Consumer::Dir->new( root => '/etc/drop/' ); my $DBH=DBI->connect($db,$user,$name) or die "..."; $feed->consume(sub { my ($f,$spec,$fh)= @_; while (<$fh>) { my @f=split/,/,$_; $dbh->do('insert into foo (date,height,width) values (?,?,?)',un +def,@f); } });
Log In?
Username:
Password:

What's my password?
Create A New User
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (6)
As of 2014-07-12 00:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    When choosing user names for websites, I prefer to use:








    Results (237 votes), past polls