----- Original Message -----
From: "Donavon Lerman" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, March 04, 2002 16:26
Subject: DBI Hash problem....
> If I run the follwoing it works fine:
>
> while ($data = $sth->fetchrow_hashref) {
> print $data->{projName};
> }
>
> But if a run it with a field that starts with a number I
> get an error:
>
> while ($data = $sth->fetchrow_hashref) {
> print $data->{5yNetFinBenef};
> }
>
> How do I get around this???
What error are you getting?
Most databases won't allow column names to start with a number. If that is
the actual field name, quote it in the hash reference.
--
Mac :})
** I normally forward private questions to the appropriate mail list. **
Ask Smarter: http://www.tuxedo.org/~esr/faqs/smart-questions.html
Give a hobbit a fish and he eats fish for a day.
Give a hobbit a ring and he eats fish for an age.