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

Home -> Community -> Usenet -> c.d.o.misc -> Re: another newbie sql question , Re: ALTER

Re: another newbie sql question , Re: ALTER

From: TurkBear <johng_at_mm.com>
Date: Tue, 30 Nov 1999 19:36:38 GMT
Message-ID: <384426bb.12044909@super.news-ituk.to>

Yes, the default formatting for SqlPlus uses the size of the field as the size of the heading, so if the heading is greater than the size, it truncates...

you can do the following prior to submitting the query: column DIVISION format a10

"Lee Gold" <leegold_at_erols-nospam-.com> wrote:

>(I'm using: SQL*Plus: Release 3.3.4.0.0 Personal Oracle7 Release
>7.3.4.0.0 PL/SQL Release 2.3.4.0.0)
>
>QUES:
>note at very bottom, that the col heading "DIVISION" was truncated w/the
>"N" chopped off
>is there a linkage between the char(6) and the col heading?
>why'd it do that? ?
>
>
>
> SQL> CREATE TABLE TEAMS
> 2 (TEAMNO SMALLINT NOT NULL,
> 3 PLAYERNO SMALLINT NOT NULL,
> 4 DIVISION CHAR(6) NOT NULL,
> 5 PRIMARY KEY (TEAMNO) )
> 6 ;
>
>Table created.
>
>SQL> INSERT INTO TEAMS VALUES (1, 6, 'first');
>
>1 row created.
>
>SQL> INSERT INTO TEAMS VALUES (2, 27, 'second');
>
>1 row created.
>
>SQL> SELECT * FROM TEAMS;
>
> TEAMNO PLAYERNO DIVISI
> ------------- ---------------- --------
> 1 6 first
> 2 27 second
>
>

  -----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------    http://www.newsfeeds.com The Largest Usenet Servers in the World! ------== Over 73,000 Newsgroups - Including Dedicated Binaries Servers ==----- Received on Tue Nov 30 1999 - 13:36:38 CST

Original text of this message

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