Subject | 30 char fieldname limit? |
---|---|
Author | McKenna, Simon (RGH) |
Post date | 2004-02-26T00:37:01Z |
G'day,
Is there a way to get more than 30 characters in the fieldname
returned from a query?
I'm running into this (limitation?) using queries built from both
IBExpert and within PHP and the ADOdb abstraction library.
The queries are executing fine, it's just the result set fieldname
that is being truncated to 30 chars.
Hopefully there a config option for this somewhere? Bueller?
Have checked docs and google with no luck so far.
Using Firebird 1.5 RC8 on WinXP with latest patches,
but will also be running on Linux in production.
Tested on PHP 4.3.4 and Apache 1.3 and 2.
You may be asking yourself why is this nutter using so many
characters in a fieldname...well...the answer is thus: I've written
an automation layer on top of the PHP ADOdb abstraction library,
and since there isn't a reliable mechanism for obtaining both the
table name and field name metadata across the dozen or so
databases that ADOdb support, what I do is pre-process queries
to combine both the table name and field name into a field alias,
using a unique separator. Then after the query is run, post-process
to remove the alias an thus obtaining table and field name with no
need for meta-data. e.g.
SELECT table.field table__alias__field FROM table
It's all open source if you want to have a squizz:
http://flashpash.sshnug.com <http://flashpash.sshnug.com>
Thanks for any help...sorry for such a long first post!
peace
si
Is there a way to get more than 30 characters in the fieldname
returned from a query?
I'm running into this (limitation?) using queries built from both
IBExpert and within PHP and the ADOdb abstraction library.
The queries are executing fine, it's just the result set fieldname
that is being truncated to 30 chars.
Hopefully there a config option for this somewhere? Bueller?
Have checked docs and google with no luck so far.
Using Firebird 1.5 RC8 on WinXP with latest patches,
but will also be running on Linux in production.
Tested on PHP 4.3.4 and Apache 1.3 and 2.
You may be asking yourself why is this nutter using so many
characters in a fieldname...well...the answer is thus: I've written
an automation layer on top of the PHP ADOdb abstraction library,
and since there isn't a reliable mechanism for obtaining both the
table name and field name metadata across the dozen or so
databases that ADOdb support, what I do is pre-process queries
to combine both the table name and field name into a field alias,
using a unique separator. Then after the query is run, post-process
to remove the alias an thus obtaining table and field name with no
need for meta-data. e.g.
SELECT table.field table__alias__field FROM table
It's all open source if you want to have a squizz:
http://flashpash.sshnug.com <http://flashpash.sshnug.com>
Thanks for any help...sorry for such a long first post!
peace
si