in reply to print() on closed filehandle..

Did you look at the file afterward to see if it actually had new data appended to it?

Always ALWAYS check for success/failure of your opens. It's easy....

 open(OUT, ">>$sql_file") or die "Guess what, it didn't work!\n$!";

If I had to guess, I'd say that your script doesn't have proper permissions with the file you're trying to write to and open.

To answer your second question, you can say, " no warnings qw/vars/; " in the appropriate section of code, and then restart them later. The warnings pragma gives pretty good flexibility.


Dave