X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id BFB87D1B50B for ; Wed, 12 Nov 2003 22:17:34 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 78891-06 for ; Wed, 12 Nov 2003 18:17:05 -0400 (AST) Received: from smtp1.mts.net (smtp1.mts.net [205.200.16.74]) by svr1.postgresql.org (Postfix) with ESMTP id 38E9FD1B507 for ; Wed, 12 Nov 2003 18:16:59 -0400 (AST) Received: from Dell4500 (wnpgmb01bbw-ac01-9-164.dial.mts.net [142.161.9.164]) by smtp1.mts.net (8.12.8-20030918/8.11.3) with SMTP id hACMGT4X000529 for ; Wed, 12 Nov 2003 16:16:30 -0600 (CST) Message-ID: <00ac01c3a96a$a165b290$6400a8c0@Dell4500> From: "George Weaver" To: Subject: Looks are important Date: Wed, 12 Nov 2003 16:12:28 -0600 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_00A9_01C3A937.C4A6B160" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1158 X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 X-Virus-Scanned: by amavisd-new at postgresql.org X-Spam-Status: No, hits=0.4 tagged_above=0.0 required=5.0 tests=HTML_60_70, HTML_FONT_COLOR_BLUE, HTML_FONT_COLOR_GREEN X-Spam-Level: X-Archive-Number: 200311/143 X-Sequence-Number: 15958 This is a multi-part message in MIME format. ------=_NextPart_000_00A9_01C3A937.C4A6B160 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hi Everyone, I am trying to concatenate two fields through a query: SELECT RPAD(no,30,' ') || tableb.kind FROM tablea=20 WHERE tablea.kind =3D tableb.kind The result gives (for example): 4595448 Green 5966 Yellow 106-60033 Green 15-94-387 Red 217-991173 Blue What I would like to have is better alignment: 4595448 Green 5966 Yellow 106-60033 Green 15-94-387 Red 217-991173 Blue Is there some kind of encoding or other string options that will result in = better alignment than what I've tried with Rpad? Thanks in advance, George ------=_NextPart_000_00A9_01C3A937.C4A6B160 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
Hi Everyone,
 
I am trying to concatenate two fields thro= ugh a=20 query:
 
SELECT= =20 RPAD(no,30,' ') || tableb.kind FROM <= FONT=20 color=3D#008000>tablea 
WHERE=20 tablea.kind =3D tableb.kind
 
The result gives (for=20 example):
 
4595448          = ;            = =20 Green
5966          &n= bsp;            = ;  =20 Yellow
106-60033         &n= bsp;          =20 Green
15-94-387         &nb= sp;          =20 Red
217-991173         &nbs= p;         =20 Blue
 
What I would like to have i= s better=20 alignment:
 
4595448          = ;           Green5966           &nbs= p;            &= nbsp;=20 Yellow
106-60033         &n= bsp;        Green
15-94-387 = ;            &n= bsp;     Red
217-991173    =             &nb= sp;Blue
 
Is there some kind of encoding or other st= ring=20 options that will result in better alignment than what I've tried with=20 Rpad?
 
Thanks in advance,
George
 
 
 
 
------=_NextPart_000_00A9_01C3A937.C4A6B160--