#!/usr/bin/perl -w use strict; use DBI; my ($dbh,$sth,$count); $dbh = DBI->connect ("DBI:mysql:host=boognish;database=benchwarmer", "joda","waliays", {PrintError => 0, RaiseError => 1}); $sth = $dbi->prepare('INSERT INTO main (operations,seconds,usr,sys,cpu,tests) VALUES (?,?,?,?,?,?)'); my $input_file = '/path/to/RUN-mysql-win2k.txt'; open(INFO, "< $input_file") or die $!; while () { # does parse to list and write to db in one swell foop $sth->execute( split " " ); } close INFO or die $!; $sth->finish; $dbi->disconnect;