public inbox for [email protected]  
help / color / mirror / Atom feed
From: Dave Page <[email protected]>
To: Surinder Kumar <[email protected]>
Cc: pgadmin-hackers <[email protected]>
Subject: Re: [pgAdmin4][Patch]: RM1840 - cannot create gist index due to enforced ASC, DESC options in generated SQL
Date: Fri, 25 Nov 2016 11:46:38 +0000
Message-ID: <CA+OCxoyCJuY-Edh7K8uX8v9f+uYAS0YpQMmnzqPn5AZyY9WgKw@mail.gmail.com> (raw)
In-Reply-To: <CAM5-9D97YhGDXQZfOg+FBf0nDedQvydWH+mAmr2iRi0rOL9PSA@mail.gmail.com>
References: <CAM5-9D-ti4O0bE3W_=puMMWPjO4qR525gYfKuGSYAiGow-AZdQ@mail.gmail.com>
	<CA+OCxowGDMCf_YJauW=u24X_7X4XMnT5tkca4qMRZCpH8z2mDA@mail.gmail.com>
	<CAM5-9D8XX_BVPi2XQODAK5DPRrhi9sTMHQDh_KTu0p9FjkU=dQ@mail.gmail.com>
	<CA+OCxozBD1OBWQTG5SvdnVFipuScgK1nNaXUxazDSXqif_gtzQ@mail.gmail.com>
	<CAM5-9D8osVRFd4s9kps-Bnuqw53WPFT4TN8ayuOO0Hr5nzuwxA@mail.gmail.com>
	<CA+OCxowo2158=USKZ1nFvpogA4BO2R3UcHHC6xWzSsiGOdj6eg@mail.gmail.com>
	<CAM5-9D97YhGDXQZfOg+FBf0nDedQvydWH+mAmr2iRi0rOL9PSA@mail.gmail.com>
List-Unsubscribe:  <mailto:[email protected]?body=unsub%20pgadmin-hackers>

On Thu, Nov 24, 2016 at 12:13 PM, Surinder Kumar
<[email protected]> wrote:
> Hi
>
> Please find updated patch with change.
>
> On Fri, Oct 21, 2016 at 9:16 PM, Dave Page <[email protected]> wrote:
>>
>> On Fri, Oct 21, 2016 at 4:42 PM, Surinder Kumar
>> <[email protected]> wrote:
>> > On Fri, Oct 21, 2016 at 8:52 PM, Dave Page <[email protected]> wrote:
>> >>
>> >> Hi
>> >>
>> >> On Fri, Oct 21, 2016 at 4:16 PM, Surinder Kumar
>> >> <[email protected]> wrote:
>> >> > Hi
>> >> >
>> >> > This fix is for exclusion constraint.
>> >> > The options like "order" and "nulls" must be conditional. i.e.
>> >> > include
>> >> > only
>> >> > when access method type is other than "gist".
>> >>
>> >> When creating an index, the asc/desc options are disabled if gist/gin
>> >> used. I think they also should be here.
>> >>
>> >> Also, what about gin indexes in this case?
>> >
>> > As per documentation,
>> > The access method must support amgettuple (see Chapter 52); at present
>> > this
>> > means GIN cannot be used
>>
>> OK, but this patch (unlike the last one) only seems to check for gist.
>
> I have modified the code so It will check for 'gist' and 'spgist'

Hi,

This still doesn't seem right to me. For example, if I choose an
access method that doesn't have a default operator class for the
selected data type, Postgres asks me to explicitly choose one, which I
now can't because the combo box is disabled. Conversely, whilst the
opclass should probably not be disabled, the ASC/DESC and NULLs
FIRST/LAST options probably should be disabled (right now, they're
just ignored).

Thoughts?

-- 
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


-- 
Sent via pgadmin-hackers mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers



view thread (14+ 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: [pgAdmin4][Patch]: RM1840 - cannot create gist index due to enforced ASC, DESC options in generated SQL
  In-Reply-To: <CA+OCxoyCJuY-Edh7K8uX8v9f+uYAS0YpQMmnzqPn5AZyY9WgKw@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