Unrelated to your question, you could simplify your spGetCurrentDateTime sub using POSIX and localtime (both of which are in the core Perl distribution) as follows:
use POSIX qw(strftime);
sub spGetCurrentDateTime {
return strftime('%b %d %Y', localtime);
}