Re: BUG #15334: Partition elimination not working as expected when using enum as partition key - Mailing list pgsql-bugs

From Andrew Gierth
Subject Re: BUG #15334: Partition elimination not working as expected when using enum as partition key
Date
Msg-id 8736v938jq.fsf@news-spur.riddles.org.uk
Whole thread Raw
In response to Re: BUG #15334: Partition elimination not working as expected whenusing enum as partition key  (Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>)
Responses Re: BUG #15334: Partition elimination not working as expected whenusing enum as partition key
List pgsql-bugs
>>>>> "Amit" == Amit Langote <Langote_Amit_f8@lab.ntt.co.jp> writes:

 Amit> Andrew also mentioned a workaround in his reply to use setString
 Amit> such that JDBC doesn't pass 'MONTH' as of type 'text' and instead
 Amit> as of unknown type. I could't find the documentation of Postgres
 Amit> JDBC's setString to see how one can do that, but maybe you can
 Amit> try it out.

Disclaimer: I don't do java stuff myself, all I know about this is from
reading the code.

First, there's a connection parameter stringtype=unspecified that
affects all setString calls on the connection. Second, there may be a
way to use setObject instead; setObject(1, str, Types.DISTINCT) looks
like it might work (or maybe Types.OTHER) - unless I'm completely
misreading the pgjdbc code, that should end up sending the right thing
to the server.

-- 
Andrew (irc:RhodiumToad)


pgsql-bugs by date:

Previous
From: PG Bug reporting form
Date:
Subject: BUG #15341: postgresql is not running
Next
From: Damir Ciganović-Janković
Date:
Subject: Re: BUG #15334: Partition elimination not working as expected whenusing enum as partition key