CREATE PROCEDURE TestProc @InField varchar(50) AS INSERT INTO TestTable (InField) VALUES (@InField) SELECT @@identity GO #### ..connect to db.. my $sth = $dbh->prepare('{call TestProc(?)}'); my $a = "TEST"; $sth->bind_param(1, $a) or die $sth->errstr; $sth->execute(); my $results = $sth->fetch(); $sth->finish(); $dbh->disconnect; print "results are $$results[0]\n";