array_agg cast issue

From: Peter Neave <Peter(dot)Neave(at)jims(dot)net>
To: "pgsql-novice(at)postgresql(dot)org" <pgsql-novice(at)postgresql(dot)org>
Subject: array_agg cast issue
Date: 2017-05-19 04:20:18
Message-ID: eb594613619340dfb63923c1ea763696@EXCH1.WEATHERTOP.local
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Hi,

We moved our development database from Windows (PostgreSQL 9.0.1, compiled by Visual C++ build 1500, 64-bit to) to Linux (PostgreSQL 9.6.1 on x86_64-pc-linux-gnu, compiled by gcc (Debian 4.9.2-10) 4.9.2, 64-bit). When using pgAdmin 4 (v1.4) and DataGrip I get an occasional error message as I’m clicking on table names.

For example
ERROR: function array_agg(bigint) is not unique
Hint: Could not choose a best candidate function. You might need to add explicit type casts.
Position: 255.
(439ms)

For example, when I’m in pgAdmin and I click on a view with the “SQL” tab on I get
ERROR: function array_agg(text) is not unique
LINE 16: array_agg(provider || '=' || label)
^
HINT: Could not choose a best candidate function. You might need to add explicit type casts.

I also get a similar issue with this query which seems to work fine on other databases created freshly on 9.6.1.
select array_agg(1::bigint);

The obvious thing to do is to create a cast – how do I do that? Has there been a change in the default casts from 9.0 to 9.6.1?

Peter

Peter Neave | Software Developer | Peter(dot)Neave(at)jims(dot)net

________________________________
48 Edinburgh Rd | Mooroolbark | VIC, 3138
P 1300 130 490 | Intl +61 3 8419 2910

Our priority is the welfare of our Franchisees.
Our aim is to sign Franchisees and Franchisors we are convinced will succeed.
Our mantra is passion for providing great customer service.
Jim Penman - Founder, Jim's Group

[Jim's Group Mantra]<http://www.jims.net>

[JIm's Group - Established 1989]<http://www.jims.net>

This email and any attachment(s) are confidential. If you are not the intended recipient you must not copy, use, disclose, distribute or rely on the information contained in it. If you have received this email in error, please notify the sender immediately by reply email and delete the email from your system. Confidentiality and legal privilege attached to this communication are not waived or lost by reason of mistaken delivery to you. While Jim's Group employs Anti-Virus Software, we cannot guarantee that this email or the attachment(s) are unaffected by computer virus, corruption or other defects and we recommend that this email and any attachments be tested before opening.

Please consider the environment before printing this email.

--
Message protected by MailGuard: e-mail anti-virus, anti-spam and content filtering.
http://www.mailguard.com.au

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message Tom Lane 2017-05-19 06:10:36 Re: array_agg cast issue
Previous Message Pankaj Arora 2017-04-27 15:00:31 Re: Change PostgreSQL Default Password Encryption