Hey all...
I think I've found a stumbling block for myself, but I'd like to find out if there's something I don't know before I start making lots of changes.
We recently changed column names to a shorter format, and in most of our code we are currently using a "table.column" format.
I have been a big fan of fetchrow_hashref for a while, and so I've used it in many, many, many places.
So now, when I get my hash back, the keys look like this:
"address_1" "city" "state"
...when I need them to look like this:
"address.address_1" "address.city" "address.state"
The two changes I am considering are to: 1)use a fetchrow_array, and list my values out; or 2)use " AS " in my SELECT statements. I hate both options.
Is there a way to tell MySQL and/or the DBI that I want the table.column format in my hash keys?
There is another question out there that is similar to mine, but the answer wasn't what I was looking for, and I just want to know if there is a better solution for me.
Here is that link:
How do I get "table.column" format from a select/join?Thanks so much,
Dale
In reply to fetchrow_hashref, and table.column format by bigperm
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |