Thread: How to make

    #1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2012
    Posts
    1
    Rep Power
    0

    How to make


    how can I reduce the size of ------------- when table is null.
    I m in sqlplus
    I type
    Select A,B,C,D,F,G,H from SOMEHERE where B='GOAT1';

    if A is 10 char long
    B is 50
    c is 10
    d is 30
    e is 10
    f is 50

    if any of those don't have data it still outputs
    ------------------------------ (50) for B and tht covers the whole screen

    how can I make is to show less if it null

    Thanks.
  2. #2
  3. Contributing User
    Devshed Novice (500 - 999 posts)

    Join Date
    Sep 2006
    Posts
    840
    Rep Power
    387
    Originally Posted by zit1343
    how can I reduce the size of ------------- when table is null.
    ... Etc ...
    how can I make is to show less if it null
    Perhaps if you took the time to read the fine SQL*PlusŪ User's guide and reference, you would find the answer.
  4. #3
  5. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    May 2012
    Posts
    14
    Rep Power
    0

    TRIM() function


    Hello,

    The TRIM() function can be used to remove white space from a field with the CHAR data type.

    For example, if you run the following query, you'll see 5 dashes, because the string is 5 characters long:

    SELECT 'TEST ' FROM DUAL;

    But if you run the next query, there will only be 4 dashes, because TRIM() will have removed the empty character from the end of the string:

    SELECT TRIM('TEST ') FROM DUAL;

    Regards,

    Joe

IMN logo majestic logo threadwatch logo seochat tools logo