Re: BUG #8352: Using UPPER in ON clause of JOIN

From: Vik Fearing <vik(dot)fearing(at)dalibo(dot)com>
To: dyuen(at)rbauction(dot)com
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #8352: Using UPPER in ON clause of JOIN
Date: 2013-08-02 07:05:56
Message-ID: 51FB5A54.6080101@dalibo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On 08/02/2013 01:48 AM, dyuen(at)rbauction(dot)com wrote:
> The following bug has been logged on the website:
>
> Bug reference: 8352
> Logged by: Daisy
> Email address: dyuen(at)rbauction(dot)com
> PostgreSQL version: 9.2.4
> Operating system: Windows 7
> Description:
>
> When joining two tables on a varchar column wrapped in a upper statement,
> the join does not work if there is a trailing space in both of the varchar
> values.
>
>
> In the two examples below, VALUE1 and VALUE2 = "ABC "
>
>
> -- Doesn't work
>
>
> SELECT * FROM TABLE1 INNER JOIN TABLE2 ON UPPER(VALUE1) = UPPER(VALUE2)
>
>
> -- Works
>
>
> SELECT * FROM TABLE1 INNER JOIN TABLE2 ON UPPER(TRIM(VALUE1)) =
> UPPER(TRIM(VALUE2))

I am unable to reproduce this. Can you provide a self-contained example
please?

Vik

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Klaus Ita 2013-08-02 07:51:34 Re: BUG #8347: PANIC: heap_insert_redo: failed to add tuple when applying WAL
Previous Message alex 2013-08-02 07:03:42 BUG #8354: stripped positions can generate nonzero rank in ts_rank_cd