doing unloads with trim function ?
Posted in 2008
Topics: Migration, Import/Export & Data Conversion
Does anyone know if there is any environment variable or something that can cause unloads and or exports to trim fields of excess spaces ? Thanks, floyd
Floyd Wellershaus wrote: > Does anyone know if there is any environment variable or something that > can cause unloads and or exports to trim fields of excess spaces ? > > Thanks, > floyd > Dunno but I've always used a sed script. -- Ian Hotmail is for spammers. Real mail address is igoddard at nildram co uk
2008/12/2 Ian Goddard <goddai01@hotmail.co.uk>: > Floyd Wellershaus wrote: >> Does anyone know if there is any environment variable or something that >> can cause unloads and or exports to trim fields of excess spaces ? >> >> Thanks, >> floyd >> > > Dunno but I've always used a sed script. > > -- > Ian > > Hotmail is for spammers. Real mail address is igoddard > at nildram co uk > _______________________________________________ > Informix-list mailing list > Informix-list@iiug.org > http://www.iiug.org/mailman/listinfo/informix-list > Floyd What leads you to believe the space is not trimmed. On IDS9.4
On Dec 2, 9:38 pm, "Floyd Wellershaus" <fl...@fwellers.com> wrote: > Does anyone know if there is any environment variable or something that can cause unloads and or exports to trim fields of excess spaces ? > > Thanks, > floyd i understood space at the end of the character string was removed Other spaces at the beginning and in the middle of the text are needed for the import of the data or you would end up with different data from that which you exported, so they remain
scottishpoet wrote: > On Dec 2, 9:38 pm, "Floyd Wellershaus" <fl...@fwellers.com> wrote: >> Does anyone know if there is any environment variable or something that can cause unloads and or exports to trim fields of excess spaces ? >> >> Thanks, >> floyd > > i understood space at the end of the character string was removed > > Other spaces at the beginning and in the middle of the text are needed > for the import of the data or you would end up with different data > from that which you exported, so they remain Spaces at the end of CHAR are not put on the unload file. Spaces at the end of VARCHAR are put on the unload file. Empty strings and nulls are particular cases. Everything in the unload/load works with the idea that you will get exacly what you had in the source. This may not be friendly when people use "simple" unload files to move data across applications. Regards. -- Fernando Nunes Portugal http://informix-technology.blogspot.com My email works... but I don't check it frequently...