First blush is to cast to a character with specific length:
Cast substr(field,3,6) as char(6)

Loyd Goodbar
Senior programmer/analyst
BorgWarner
TS Water Valley
662-473-5713

-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Aaron Abreu
Sent: Thursday, March 20, 2008 14:49
To: midrange-l@xxxxxxxxxxxx
Subject: building new fields using substr in sql


I have been substring data from pieces of
fields and outputting the fields to a physical file
created new by the sql run

I keep getting 2 extra positions of "non-diplayable"
data in front of any field I "built", but not in front
of a whole field that already existed,

this causes the desired record lenth to be off
by multiples of 2 (for each occurrance of a substr'd field)

How do I get around those control bytes so they do
NOT add to my record length.

thanks in advance for your help.



The information contained in this message may be privileged and
confidential and protected from disclosure. If the reader of this
message is not the intended recipient, or an employee or agent
responsible for delivering this message to the intended recipient, you
are hereby notified that any dissemination, distribution or copying of
this communication is strictly prohibited. If you have received this
communication in error, please notify us immediately by replying to the
message and deleting it from your computer. Under Florida law, e-mail
addresses are public records. If you do not want your e-mail address
released in response to a public-records request, do not send electronic
mail to this entity. Instead, contact this office by phone or in
writing.


This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2019 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].