good chemistry is complicated,
and a little bit messy -LW
Querying and parsing MySQL data typesby LanX (Archbishop)
|on Nov 30, 2018 at 21:58 UTC||Need Help??|
LanX has asked for the
wisdom of the Perl Monks concerning the following question:
I'm most probably reinventing the wheel
I had to write a parser to parse mysql types like
I tried DBI::column_info and querying information_schema.`COLUMNS` but couldn't get anything which didn't required writing a parser.
My job involves writing many HTML/JS GUIs for our data models and my colleagues are quite "agile" in changing data-models on the fly. Our schemas are replicated (but not synchronized) on different servers.
Now I'm trying to automate type-checking and form generation on the GUI level.
Such that enum('Y','N') results in a [ ] check box and enum('export','import','view') in a select menu.
actually using DBI::column_info I'm getting quite detailed informations for enum
but informations like unsigned and zerofill seem to get lost.
fixed format issue, thanks stevieb++