Re: Add CREATE DATABASE LOCALE option

2019-07-23 Thread Peter Eisentraut
On 2019-07-23 00:18, Fabien COELHO wrote: > It applies cleanly, compiles, global & pg_dump make check ok, doc gen ok. > > I'm still unconvinced of the interest of breaking backward compatibility, > but this is no big deal. > > I do not like much calling strlen() to check whether a string is empt

Re: Add CREATE DATABASE LOCALE option

2019-07-22 Thread Fabien COELHO
Hello Peter, About the pg_dump code, I'm wondering whether it is worth generating LOCALE as it breaks backward compatibility (eg dumping a new db to load it into a older version). We don't really care about backward compatibility here. Moving forward, with ICU and such, we don't want to hav

Re: Add CREATE DATABASE LOCALE option

2019-07-22 Thread Peter Eisentraut
On 2019-07-13 19:20, Fabien COELHO wrote: > The second error message about conflicting option could more explicit than > a terse "conflicting or redundant options"? The user may expect later > options to superseedes earlier options, for instance. done > About the pg_dump code, I'm wondering whe

Re: Add CREATE DATABASE LOCALE option

2019-07-13 Thread Fabien COELHO
Hello Peter, I think pg_dump/t/002_pg_dump.pl might be a good place. Not the easiest program in the world to work with, admittedly. Updated patch with test and expanded documentation. Patch v2 applies cleanly, compiles, make check-world ok with tap enabled. Doc gen ok. The addition loo

Re: Add CREATE DATABASE LOCALE option

2019-06-23 Thread Peter Eisentraut
On 2019-06-06 21:52, Alvaro Herrera wrote: > On 2019-Jun-06, Fabrízio de Royes Mello wrote: > Cool... would be nice also add some test cases. >>> >>> Right. Any suggestions where to put them? >> >> Hmm... good question... I thought we already have some regression tests for >> {CREATE|DROP} D

Re: Add CREATE DATABASE LOCALE option

2019-06-14 Thread Heikki Linnakangas
On 05/06/2019 23:17, Peter Eisentraut wrote: I propose this patch to add a LOCALE option to CREATE DATABASE. This sets both LC_COLLATE and LC_CTYPE with one option. Similar behavior is already supported in initdb, CREATE COLLATION, and createdb. With collation providers other than libc, having

Re: Add CREATE DATABASE LOCALE option

2019-06-06 Thread Alvaro Herrera
On 2019-Jun-06, Fabrízio de Royes Mello wrote: > > > Cool... would be nice also add some test cases. > > > > Right. Any suggestions where to put them? > > Hmm... good question... I thought we already have some regression tests for > {CREATE|DROP} DATABASE but actually we don't... should we add a

Re: Add CREATE DATABASE LOCALE option

2019-06-06 Thread Fabrízio de Royes Mello
On Thu, Jun 6, 2019 at 6:38 AM Peter Eisentraut < peter.eisentr...@2ndquadrant.com> wrote: > > On 2019-06-05 22:31, Fabrízio de Royes Mello wrote: > > On Wed, Jun 5, 2019 at 5:17 PM Peter Eisentraut > > > > wrote: > >> > >> I propose this patch to add a LOC

Re: Add CREATE DATABASE LOCALE option

2019-06-06 Thread Peter Eisentraut
On 2019-06-05 22:31, Fabrízio de Royes Mello wrote: > On Wed, Jun 5, 2019 at 5:17 PM Peter Eisentraut > > wrote: >> >> I propose this patch to add a LOCALE option to CREATE DATABASE.  This >> sets both LC_COLLATE and LC_CTYPE with one option.  Similar behav

Re: Add CREATE DATABASE LOCALE option

2019-06-05 Thread Fabrízio de Royes Mello
On Wed, Jun 5, 2019 at 5:17 PM Peter Eisentraut < peter.eisentr...@2ndquadrant.com> wrote: > > I propose this patch to add a LOCALE option to CREATE DATABASE. This > sets both LC_COLLATE and LC_CTYPE with one option. Similar behavior is > already supported in initdb, CREATE COLLATION, and created