Received: from morpheus.webprojkt.com (morpheus.webprojkt.com [209.61.155.148]) by mail.postgresql.org (8.11.1/8.11.1) with SMTP id f17G82x70118 for ; Wed, 7 Feb 2001 11:08:02 -0500 (EST) (envelope-from brice@webprojkt.com) Received: (qmail 30022 invoked by uid 604); 7 Feb 2001 16:07:57 -0000 Received: from unknown (HELO webprojkt.com) (216.170.131.123) by morpheus.webprojkt.com with SMTP; 7 Feb 2001 16:07:57 -0000 Message-ID: <3A8172DD.C91DDCF2@webprojkt.com> Date: Wed, 07 Feb 2001 10:07:55 -0600 From: Brice Ruth X-Mailer: Mozilla 4.76 (Macintosh; U; PPC) X-Accept-Language: en MIME-Version: 1.0 To: Tom Lane CC: Michael Fork , Ian Harding , pgsql-general@postgresql.org, pgsql-sql@postgresql.org Subject: Re: [SQL] Re: SQL Join - MySQL/PostgreSQL difference? References: <3A816921.FEB47B80@webprojkt.com> <28366.981560901@sss.pgh.pa.us> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Archive-Number: 200102/337 X-Sequence-Number: 4210 Here's my latest tactic: I'm guessing that the data 'corruption' has something to do with the way the data was exported from the original database by the third party ... probably something with the cr/lf linebreaks or something to that effect (the data field in question happens to be the last field in a line in the data file). So, I loaded up all the files in my text editor (BBedit) and saved 'em back out w/ UNIX linebreaks, then transferred the files as a bzipped tar over to the server. I deleted all the content from the db and am reimporting via 'COPY ... FROM' as I write this. Its about 100MB of data so it'll take a few minutes to import. I'll report back any successes ... if things fail again, I'll follow all the advice I've gotten to this point then report back with any discoveries. Thank you SO much for all the help with this. I really appreciate it tremendously. -Brice Tom Lane wrote: > > Brice Ruth writes: > > SELECT length(monographid) FROM tblpemdruglink WHERE drugid='DG-5039'; > > I get 5 returned to me, even though the string is only 4 ('2008'). > > Okay, so you've got some invisible character in there, but not a space > (else the trim() woulda got rid of it). Tab maybe? Might want to go > back and examine your original data file more carefully, with an editor > that will show you control characters and such. > > regards, tom lane -- Brice Ruth WebProjkt, Inc. VP, Director of Internet Technology http://www.webprojkt.com/