Hi Onteria,
On Monday 13 December 2010 02:52:42 Onteria wrote:
> I just finished working on a solution for the exercises provided in the
> tutorial located here:
>
> A Beginner's Introduction to Perl 5.10 - Perl.com
> http://bit.ly/dHvsqC
> (shortened to prevent cutoff)
>
> Instructions for the
On Mon, Dec 13, 2010 at 1:05 AM, John W. Krahn wrote:
> shawn wilson wrote:
>>
>> i'm trying to exclude undefined variables for that are to be put into
>> a sql database date field, but none of this is working:
>>
>> sub correctdate { # make valid sql DATE field
>> my $date = $_[ 0
shawn wilson wrote:
i'm trying to exclude undefined variables for that are to be put into
a sql database date field, but none of this is working:
sub correctdate { # make valid sql DATE field
my $date = $_[ 0 ];
my ($month, $day, $year) = split / /, $date if defined( $date )
You are declaring $corrected within the if block -- After it ends, the
variable goes out of scope, making a strict[0] Perl blow up in your face. As
you have warnings enabled, it shows that message (which you can look up in
perldiag is you don't quite get [1]).
The solution is simple: You just need
On Sun, Dec 12, 2010 at 8:11 PM, shawn wilson wrote:
> i'm trying to exclude undefined variables for that are to be put into
> a sql database date field, but none of this is working:
errr, sorry, my error with the current code is:
Global symbol "$corrected" requires explicit package name at
./usc
i'm trying to exclude undefined variables for that are to be put into
a sql database date field, but none of this is working:
sub correctdate { # make valid sql DATE field
my $date = $_[ 0 ];
my ($month, $day, $year) = split / /, $date if defined( $date );
$day =~ s/,//g if
On Sun, Dec 12, 2010 at 7:52 PM, Onteria wrote:
> I just finished working on a solution for the exercises provided in the
> tutorial located here:
>
> A Beginner's Introduction to Perl 5.10 - Perl.com
> http://bit.ly/dHvsqC
> (shortened to prevent cutoff)
>
> Instructions for the exercise:
> "Give
I just finished working on a solution for the exercises provided in the
tutorial located here:
A Beginner's Introduction to Perl 5.10 - Perl.com
http://bit.ly/dHvsqC
(shortened to prevent cutoff)
Instructions for the exercise:
"Given a month and the day of the week that's the first of that month,