in reply to if ($?variable_name)

nothing, it's a syntax error

Bareword found where operator expected

you're sure you didn't confuse the programming language?

Cheers Rolf

( addicted to the Perl Programming Language)

PS: FWIW $? exists!