Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Is is possible to do this in SQL*Plus........

Re: Is is possible to do this in SQL*Plus........

From: Jonathan Gennick <jonathan_at_gennick.com>
Date: Sat, 03 Apr 1999 21:33:39 GMT
Message-ID: <370788ca.1246098@netnews.worldnet.att.net>


On Sat, 03 Apr 1999 11:49:22 -0800, Jimmy <c6635500_at_comp.polyu.edu.hk> wrote:

> i.e. format the output such that each field output has the fixed length
>(each field may have different fixed length and field type is varchar2,
>number with decimal poing or date format). If the length of field value
>is larger than the fixed length of this field, truncate the field value
>to the fixed length of this field.

To truncate long values, as opposed to wrapping them, formath the column as follows:

column X format A10 truncated
select X from some_table;

This should result in a 10 character wide column, with any longer values being truncated.

regards,

Jonathan Received on Sat Apr 03 1999 - 15:33:39 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US