
my $o = do_inbgu($real->body);

my $sth2 = $dbh->prepare(qq{insert into table(job_id, gods, pdb, score, start, seq) 
                                       values(?,?,?,?,?,?)}) or die $dbh->errstr;
	    
foreach my $item (keys %$o) {

    for ($c=0; $c < 10; $c++) {
	$sth2->execute($item,
		       $c+1,
		       defined($o->{$item}->[$c]->[0]) ? $o->{$item}->[$c]->[0] : '',
		       defined($o->{$item}->[$c]->[1]) ? $o->{$item}->[$c]->[1] : '',
		       ($offset > 0) ? $offset : 0,
		       defined($o->{$item}->[$c]->[2]) ? $o->{$item}->[$c]->[2] : ''
		      ) or warn $sth2->errstr;
    }
}

$sth1->finish;
$sth2->finish;
}
