how to adjust the column width for a result set?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • bhakhra
    New Member
    • Jan 2008
    • 6

    how to adjust the column width for a result set?

    Hi all,
    I am retriving two columns and the result set is not fitting on the screen due to a wider column width..how can get rid of the extra spaces in between the two columns...
  • docdiesel
    Recognized Expert Contributor
    • Aug 2007
    • 297

    #2
    Hi,

    if I understand you right you're displaying two columns with usually a couple of chars and lots of white space in between? You could cut them into place with substr() :

    Code:
    SELECT
      substr(name,1,20)    as name,
      substr(comment,1,60) as comment
    FROM
      ...
    Regards,

    Bernd

    Comment

    • bhakhra
      New Member
      • Jan 2008
      • 6

      #3
      Originally posted by docdiesel
      Hi,

      if I understand you right you're displaying two columns with usually a couple of chars and lots of white space in between? You could cut them into place with substr() :

      Code:
      SELECT
        substr(name,1,20)    as name,
        substr(comment,1,60) as comment
      FROM
        ...
      Regards,

      Bernd
      thats exactly what I was looking for..
      thank you very much,

      Sunny

      Comment

      Working...