Re: A question about exporting
Posted in 1993
Topics: Data Types & Schema Design, Migration, Import/Export & Data Conversion, Jobs, Consulting & Announcements
> I ran a test and saw that the dbexport command will show a null value
> properly (||), but with a zero length string (not null mind you) it
> pads it to a single space.
>
> The question: How the heck do I keep dbexport from altering my data?
I don't think it will alter your data.
Except for varchar types Informix stores character data padded to the
maximum length of the field. For example, if I have a name field
defined 'name char(32)', the internal representation will be to pad
"Washington, George" with 14 more spaces. Those spaces are not
significant in comparisons. An extension of that logic says that an
empty string will be padded to 32 blanks.
dbexport, to save space I presume, clips the trailing blanks from
character fields on export. The only exception is when it tries to clip
an empty string, it will leave the first blank to distinguish it from
null.
--
Take Care --
Eric
-----------------------------------------------------------------------------
Pi seconds is a nano-century.