[freetds] testing using tsql
medi at resonate.com
Wed Jun 20 21:40:27 EDT 2007
I am trying to find a way to test an MS SQL engine using tsql(1) from a
My input file has over 47000 SQL statements in it.
So I rolled up a perl script to say...
my $input = IO::File->new ( "inputfile.sql");
my $output = IO::File->new( "| tsql -H host -P port -U xx -P xxx");
$more = $sql = getSql ( $in );
sendSql ($out, $sql);
sleep(2); # watch some TV, etc
} while ( $more );
My problem is with my writes to the pipe above. And tsql prompts and
bunch of error messages...I might have to insert a function called
recvResponse() after sendSQL()....and that is where I said, I bet
someone has already done this....
has anyone cooked up a utilitiy like this....I need to be able to insert
sleep between sql requests....that is why I can 'nt use tsql itself
Or maybe there is a way ...
More information about the FreeTDS