Hello,
I'm trying to put together a script that involves pulling data from a config file. I'm attempting to write an if statement to validate one of the pieces of data from the config file, but I think I'm fat fingering it somehow.
$config{VALUE} is being pulled from a config file but can only be one of three options. The hope is to write an if statement to ensure that $config{VALUE} is one of those 3 options.
This is what I'm attempting to use, but if intentionally supply an invalid option, it doesn't catch.
if (($config{VALUE} ne "A") || ($config{VALUE} ne "B") || ($config{VALUE} ne "C"))
{
die "Missing or Invalid VALUE.";
}