Re: Truncation
Posted in 1994
naomi@anasazi.com (Naomi Walker) writes:
>A quickie for y'all....
> What would be the most efficient and quickest way to truncate a
> char(6) to a char(2) in an existing table?
Do you want the column to stay as a char(6), but truncate existing
values to char(2)?
Or (I'm guessing) you whant to change a CHAR(6) column to a CHAR(2),
and you want any values existing to be appropriately truncated:
ALTER TABLE tablename MODIFY (columname CHAR(2) [NOT NULL]);
Will change the table, it's values, and any corresponding indexes.
=======================================================================
Dennis J. Pimple dennisp@informix.com Opinions expressed
Senior Consultant -------------------- are mine, and do not
Informix Software Inc Voice: 303-850-0210 necessarily reflect
Denver Colorado USA Fax: 303-779-4025 those of my employer.