Meaning of TYPE_NAME in type_info() output
"Avis, Ed" <[email protected]>
| Newsgroups | gmane.comp.lang.perl.modules.dbi.sybase,gmane.comp.lang.perl.modules.dbi.general |
|---|---|
| Message-ID | <B6950B05C2FB1A418290414131B118B964C535@EXLN1-VS1.london.kbcfp.com> |
If I make a user-defined type synonym, should the name of this synonym appear as TYPE_NAME in the type_info() output or should TYPE_NAME give the original SQL type the synonym is defined as? Currently if I make a user-defined type on Sybase and use it for some column C of a table T, then for 'SELECT C FROM T' DBD::Sybase gives me the name of the user type. I think I would prefer it to give the original SQL like 'varchar(10)' in the TYPE_NAME field, but I don't know what other DBDs do. What is the intended behaviour of TYPE_NAME in this case? I'm sure other RDBMSes allow user-defined type synonyms. I think it would be best to resolve the synonym down to plain SQL type name if possible - but if that isn't possible (eg it really is a user- defined type, not just a synonym) then leave the name. -- Ed Avis <[email protected]>