#!/usr/bin/perl push (@INC, "D:\\Perl\\site\\lib"); use DBI; my $dbh = DBI->connect("dbi:SQL Server;database=Maddy17","Maddy",""); my $sth = $dbh->prepare ("select * from sysobjects where name = 'pub_titles' and type = 'P' and uid = USER_ID()"); my $sth->execute(); while (@row = $sth->fetchrow_aray()) { if (-e @row) { print "store proc exists\n"; } } my $dbh->disconnect();