public inbox for [email protected]
help / color / mirror / Atom feedFrom: Ron Johnson <[email protected]>
To: PostgreSQL <[email protected]>
Subject: Re: PostgreSQL Bug with simple function unexpectedly treating varchar parameter as an array
Date: Wed, 6 Aug 2025 16:25:59 -0400
Message-ID: <CANzqJaDOZyyRjNajL4uPbKnbxKjsyFN3UbWYv_9XyTmZ6L-iYA@mail.gmail.com> (raw)
In-Reply-To: <CAEpg1wBUcKjbM+vqP=JLHQUCOW9ct=aVRo1gBEtAZ5SuMY6cYQ@mail.gmail.com>
References: <CAEpg1wBxp=25isxj6yt2cf97KtvbwxvJfrJ9qYF8UQxGSBJ93Q@mail.gmail.com>
<[email protected]>
<CAEpg1wCDL+iYbG7ByjHcgfvJy7m3m-rDp-xKiYovvxeKTbG7iQ@mail.gmail.com>
<[email protected]>
<CAEpg1wALRocK=uDSNyJqdc=vhNGjYFmT3H_TNzihSOMS88WHfg@mail.gmail.com>
<[email protected]>
<[email protected]>
<[email protected]>
<[email protected]>
<CAEpg1wBUcKjbM+vqP=JLHQUCOW9ct=aVRo1gBEtAZ5SuMY6cYQ@mail.gmail.com>
Puzzling.
I'd do:
pg_dump --schema-only xxx_pub_dev_2_db | grep -i -A5 _sa_setup_role
Note the -i. That _might_ be important.
On Wed, Aug 6, 2025 at 4:18 PM Rumpi Gravenstein <[email protected]> wrote:
> Just coming back to this. Don't know how to interpret this:
>
> xxx_pub_dev_2_db=# select proname, pronamespace, oid from pg_proc where
> proname like '%sa_setup%';
> proname | pronamespace | oid
> ----------------+--------------+---------
> _sa_setup_role | 7038406 | 7869125
> (1 row)
>
> xxx_pub_dev_2_db=# drop FUNCTION if exists _sa_setup_role;
> DROP FUNCTION
> xxx_pub_dev_2_db=# select proname, pronamespace, oid from pg_proc where
> proname like '%sa_setup%';
> proname | pronamespace | oid
> ---------+--------------+-----
> (0 rows)
>
> xxx_pub_dev_2_db=# select _sa_setup_role('af_repo_app');
> ERROR: malformed array literal: "af_repo_app"
> LINE 1: select _sa_setup_role('af_repo_app');
> ^
> DETAIL: Array value must start with "{" or dimension information.
> xxx_pub_dev_2_db=#
>
> On Fri, Jul 25, 2025 at 4:52 PM Tom Lane <[email protected]> wrote:
>
>> Laurenz Albe <[email protected]> writes:
>> > On Fri, 2025-07-25 at 14:10 -0400, Tom Lane wrote:
>> >> So ... any chance you have a data type named _sa_setup_role?
>>
>> > ... it could also be a type "sa_setup_role", and "_sa_setup_role"
>> > is interpreted as the corresponding array type:
>>
>> Oh, of course --- that's a good deal more likely than my version.
>>
>> regards, tom lane
>>
>
>
> --
> Rumpi Gravenstein
>
--
Death to <Redacted>, and butter sauce.
Don't boil me, I'm still alive.
<Redacted> lobster!
view thread (5+ messages) latest in thread
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 using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected]
Subject: Re: PostgreSQL Bug with simple function unexpectedly treating varchar parameter as an array
In-Reply-To: <CANzqJaDOZyyRjNajL4uPbKnbxKjsyFN3UbWYv_9XyTmZ6L-iYA@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox