pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: gzh <gzhcoder@126.com>
To: Erik Wienhold <ewie@ewie.name>
Cc: pgsql-general@lists.postgresql.org
Subject: Re: function to_char(unknown) is not unique at character 8
Date: Thu, 6 Jul 2023 22:15:54 +0800 (CST)
Message-ID: <7844e14c.7bb8.1892b8f3c9c.Coremail.gzhcoder@126.com> (raw)
In-Reply-To: <269723997.937486.1688643409072@office.mailbox.org>
References: <2f8f581c.67f1.1892a7fba60.Coremail.gzhcoder@126.com>
	<269723997.937486.1688643409072@office.mailbox.org>

Thank you very much for taking the time to reply to my question. 
I added oracle to search_path, but it didn't work.


postgres=# show search_path;
             search_path
-------------------------------------
 "$user", public, oracle, pg_catalog



















At 2023-07-06 19:36:49, "Erik Wienhold" <ewie@ewie.name> wrote:
>> On 06/07/2023 11:19 CEST gzh <gzhcoder@126.com> wrote:
>>
>> I upgraded the version of PostgreSQL from 12.6 to 12.13,
>> when I execute the sql below , the to_char function caused the following error.
>>
>> ---------------SQL------------------
>> select TO_CHAR('1000000');
>>
>> ERROR: function to_char(unknown) is not unique at character 8
>> HINT: Could not choose a best candidate function. You might need to add explicit type casts.
>>
>> There is no problem before the upgrade and to_char function comes from the
>> Orafce extension.
>> The configuration of the old and new databases is as follows.
>>
>> Database server (old): PostgreSQL 12.6(orafce3.13)
>> Database server (new): PostgreSQL 12.13(orafce3.24)
>>
>> The new database has successfully installed the orafce 3.24 extension.
>> It does not occur in "PostgreSQL 12.6 and orafce 3.13",
>> but occurs in "PostgreSQL 12.13 and orafce 3.24",
>> so either the difference between 12.6 and 12.13 or the difference between
>> orafce 3.13 and 3.24 is suspicious.
>>
>> What is the reason for the problem and how to fix the error?
>
>This rings a bell:
>
>https://www.postgresql.org/message-id/1597875806.606392.1681915893771%40office.mailbox.org
>
>Either qualify functions with namespace oracle, e.g. oracle.to_char('1000000'),
>or place oracle on the search path.
>
>--
>Erik


view thread (12+ messages)  latest in thread

Message-ID: <7844e14c.7bb8.1892b8f3c9c.Coremail.gzhcoder@126.com>
Permalink:  ../7844e14c.7bb8.1892b8f3c9c.Coremail.gzhcoder@126.com/
Also on:    postgresql.org/message-id/7844e14c.7bb8.1892b8f3c9c.Coremail.gzhcoder@126.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: gzhcoder@126.com, ewie@ewie.name
  Subject: Re: function to_char(unknown) is not unique at character 8
  In-Reply-To: <7844e14c.7bb8.1892b8f3c9c.Coremail.gzhcoder@126.com>
  References: <2f8f581c.67f1.1892a7fba60.Coremail.gzhcoder@126.com> <269723997.937486.1688643409072@office.mailbox.org> <7844e14c.7bb8.1892b8f3c9c.Coremail.gzhcoder@126.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox