I wrote the following script as a windows tail + count function,
but it's too slow if the input is huge, how can it be improved?
if (!$ARGV[0]){
die("you've forgotten to enter the file name\n");
}
if (!$ARGV[1]) {
$n = 9; # output 10 rows by default
}
else {
$n = $ARG
I have a script gonnadie.pl
##gonnadie.pl
do_sth
die "blah blah";
gonnadie.pl is called by a DOS batch file x.bat
REM - x.bat
perl gonnadie.pl
x.bat is called by y.bat
REM - y.bat
x.bat
When y.bat is run, the OS treats x.bat ends sucessfully, how can I make y.bat dies
when gonnadie.pl dies
I want to pull some data down from a Teradata database to a Win2k/NT server.
I use DBI or Win32::ODBC, a system DSN (teradata1) is created.
use DBI;
use DBD::ODBC;
my $dbh = DBI->connect("DBI:ODBC:teradata1", "uname", "moo");
...
or
use Win32::ODBC;
$data = new Win32::ODBC("DSN = teradata1; UID
I think you need both DBI and DBD::ODBC.
Timothy Johnson <[EMAIL PROTECTED]> wrote in message
C0FD5BECE2F0C84EAA97D7300A500D5002581294@SMILEY">news:C0FD5BECE2F0C84EAA97D7300A500D5002581294@SMILEY...
>
> Oops. I think that was DBD, not DBI.
>
> -Original Message-
> From: Timothy Johnson [