Re: How to install pgAgent on windows for postresql-bigsql-10.5

2018-09-06 Thread Dave Page
Hi

On Thu, Sep 6, 2018 at 6:23 AM, jimmy  wrote:

> I use PostgreSQL-10.5-1-win64-bigsql.exe to install postgresql database.
> How to install pgAgent on windows for postresql-bigsql-10.5.
> I have been searching some articles to install pgAgent.
> But they do not work.
> I found there has not any version of pgAgent for windows in the website '
> www.pgadmin.org'.
> And PostgreSQL-10.5-1-win64-bigsql.exe installer also has not the pgAgent.
> When I execute CREATE EXTENSION pgagent, it throws ERROR:  could not open
> extension control file
> "H:/PostgreSQL/pg10/../pg10/share/postgresql/extension/pgagent.control":
> No such file or directory.
> How can I resolve these problems.
> Thank you.
>

If you use the EDB PostgreSQL installers, you can install pgAgent using
StackBuilder. For BigSQL you'll probably have to build and install it
manually from source (which isn't exactly easy on Windows, and is dependent
on what is included with and how BigSQL is packaged - which I know nothing
about).


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

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


Re: Re: How to install pgAgent on windows for postresql-bigsql-10.5

2018-09-06 Thread Dave Page
On Thu, Sep 6, 2018 at 9:41 AM, jimmy  wrote:

> Is EnterpriseDB opensource and free. Has this database some limits and
> restrictions ?
>

The EDB PostgreSQL installers are free, opensource and have no limits or
restrictions. They are the very first option at
https://www.postgresql.org/download/windows/


>
>
>
>
>
>
> At 2018-09-06 15:57:30, "Dave Page"  wrote:
>
> Hi
>
> On Thu, Sep 6, 2018 at 6:23 AM, jimmy  wrote:
>
>> I use PostgreSQL-10.5-1-win64-bigsql.exe to install postgresql database.
>> How to install pgAgent on windows for postresql-bigsql-10.5.
>> I have been searching some articles to install pgAgent.
>> But they do not work.
>> I found there has not any version of pgAgent for windows in the website '
>> www.pgadmin.org'.
>> And PostgreSQL-10.5-1-win64-bigsql.exe installer also has not the
>> pgAgent.
>> When I execute CREATE EXTENSION pgagent, it throws ERROR:  could not open
>> extension control file
>> "H:/PostgreSQL/pg10/../pg10/share/postgresql/extension/pgagent.control":
>> No such file or directory.
>> How can I resolve these problems.
>> Thank you.
>>
>
> If you use the EDB PostgreSQL installers, you can install pgAgent using
> StackBuilder. For BigSQL you'll probably have to build and install it
> manually from source (which isn't exactly easy on Windows, and is dependent
> on what is included with and how BigSQL is packaged - which I know nothing
> about).
>
>
> --
> Dave Page
> Blog: http://pgsnake.blogspot.com
> Twitter: @pgsnake
>
> EnterpriseDB UK: http://www.enterprisedb.com
> The Enterprise PostgreSQL Company
>
>
>
>
>



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

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


Re: Code of Conduct plan

2018-09-14 Thread Dave Page
On Fri, Sep 14, 2018 at 3:08 PM, Joshua D. Drake 
wrote:

> On 09/14/2018 01:31 AM, Chris Travers wrote:
>
>
> I apologize for the glacial slowness with which this has all been moving.
>> The core team has now agreed to some revisions to the draft CoC based on
>> the comments in this thread; see
>>
>> https://wiki.postgresql.org/wiki/Code_of_Conduct
>>
>> (That's the updated text, but you can use the diff tool on the page
>> history tab to see the changes from the previous draft.)
>>
>
> I really have to object to this addition:
> "This Code is meant to cover all interaction between community members,
> whether or not it takes place within postgresql.org infrastructure, so
> long as there is not another Code of Conduct that takes precedence (such as
> a conference's Code of Conduct)."
>
> That covers things like public twitter messages over live political
> controversies which might not be personally directed.   At least if one is
> going to go that route, one ought to *also* include a safe harbor for
> non-personally-directed discussions of philosophy, social issues, and
> politics.  Otherwise, I think this is asking for trouble.  See, for
> example, what happened with Opalgate and how this could be seen to
> encourage use of this to silence political controversies unrelated to
> PostgreSQL.
>
>
> I think this is a complicated issue. On the one hand, postgresql.org has
> no business telling people how to act outside of postgresql.org. Full
> stop.
>

I'm going to regret jumping in here, but...

I disagree. If a community member decides to join forums for other software
and then strongly promotes PostgreSQL to the point that they become abusive
or offensive to people making other software choices, then they are clearly
bringing the project into disrepute and we should have every right to
sanction them by preventing them participating in our project in whatever
ways are deemed appropriate.

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

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


Re: Code of Conduct plan

2018-09-14 Thread Dave Page
On Fri, Sep 14, 2018 at 3:13 PM, Adrian Klaver 
wrote:

> On 9/14/18 6:59 AM, Robert Eckhardt wrote:
>
>> On Fri, Sep 14, 2018 at 9:41 AM, Adrian Klaver
>>  wrote:
>>
>>> On 9/14/18 1:31 AM, Chris Travers wrote:
>>>
>>
>
>>>> I really have to object to this addition:
>>>> "This Code is meant to cover all interaction between community members,
>>>> whether or not it takes place within postgresql.org <
>>>> http://postgresql.org>
>>>> infrastructure, so long as there is not another Code of Conduct that
>>>> takes
>>>> precedence (such as a conference's Code of Conduct)."
>>>>
>>>
>>>
>>> I second that objection. It is not in PGDG's remit to cure the world, for
>>> whatever form of cure you ascribe to. This is especially true as
>>> 'community
>>> member' has no strict definition.
>>>
>>
>> I understand the concern, however, if you look at how attacks happen
>> it is frequently through other sites. Specifically under/poorly
>> moderated sites. For specific examples, people who have issues with
>> people on Quora will frequently go after them on Facebook and Twitter.
>>
>> these aren't a solution looking for a problem. If we just want to look
>> at the clusterfuck that is happening in the reddis community right now
>> we can see conversations spilling onto twitter and into ad hominem
>> vitriol.
>>
>
> Ask yourself, if this was a government agency tracking your speech across
> platforms would you be as approving? Personally I find the whole thing
> creepy.


No one is tracking anything as part of the CoC. That's nothing but a straw
man argument.

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

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


Re: Code of Conduct plan

2018-09-14 Thread Dave Page
On Fri, Sep 14, 2018 at 3:21 PM, James Keener  wrote:

>
> Now, you may say that (2) would be rejected by the committee, but I would
>>> counter that it's still a stain on me and something that will forever
>>> appear
>>> along side my name in search results and that the amount of time and
>>> stress it'd take me to defend myself would make my voluntarily leaving
>>> the community, which would be seen as an admission of guilt, my only
>>> option.
>>>
>>
>> If you had read the policy, you would know that wouldn't happen as
>> reports and details of reports are to be kept confidential.
>>
>
> That doesn't mean I won't be strung along and it doesn't mean that the
> attacker can't release those details. Remember, I'm worried
> about politically motivated attacks, and attacks meant to silence opposing
> viewpoints, not legitimate instances of harassment.
>

Sure, but an attacker can do that now. Having the CoC doesn't change
anything there, though it does give us a framework to deal with it.


>
>
>>
>>
>>>
>>> People are shitheads. People are assholes. We're not agreeing to join
>>> some organization and sign an ethics clause when signing up for the
>>> mailing
>>> list.  The current moderators can already remove bad actors from the
>>> list.
>>> How they act outside of the list is non of this list's concern.
>>>
>>
>> The lists are just one of many different ways people in this community
>> interact.
>>
>
> So? We interact with people outside of specific groups all the time.
> Baring specific
> agreements to the contrary, why should any one group claim responsibility
> of my
> personal business?
>

If that business is publicly bringing the project into disrepute, or
harassing other community members and they approach us about it, then it
becomes our business.

If it's unrelated to PostgreSQL, then it's your personal business and not
something the project would get involved in.

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

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


Re: Code of Conduct plan

2018-09-14 Thread Dave Page
On Fri, Sep 14, 2018 at 3:28 PM, Adrian Klaver 
wrote:

> On 9/14/18 7:19 AM, Dave Page wrote:
>
>>
>>
>>
>
>> No one is tracking anything as part of the CoC. That's nothing but a
>> straw man argument.
>>
>
> Not buying it or the below is null and void:
>
> "This Code is meant to cover all interaction between community members,
> whether or not it takes place within postgresql.org infrastructure, so
> long as there is not another Code of Conduct that takes precedence (such as
> a conference's Code of Conduct)."
>
> Not sure how the above can be enforced without someone reporting on what
> is said outside the 'postgresql.org infrastructure'?
>
> At any rate, whether I like it or not the CoC is here to stay. I just feel
> a dissenting opinion is important to the conversation.


I can report someone who steal my wallet to the police. That doesn't mean I
track pick-pockets activity.

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

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


Re: Code of Conduct plan

2018-09-14 Thread Dave Page
On Fri, Sep 14, 2018 at 3:41 PM, James Keener  wrote:

> > Community is people who joined it
>
> We're not a "community." We're people using email to get help with or
> discuss technical aspects of PostgreSQL. The types of discussions that
> would normally be held within a "community" would be entirely off-topic
> here.  We should be professional to each other here; we don't need to be
> buddies. There is a clear difference between "professionalism" and
> "community". A document governing interactions on this list is within the
> right of the moderation, but leaking into the "real world" is an
> abomination and perversion of what this group is.
>

To many of us, we absolutely are a community. Remember, there are people
here who have been around for 20+ years, of which many have become close
friends, having started working on PostgreSQL as a hobby. We have always
seen the project as a community of like-minded technologists, and welcome
others that wish to join, whether just to ask a single question or to hang
around for the next 20 years. I do see your viewpoint, but I would counter
that coming here for help (for example) is quite different from calling
tech support at a vendor.


>
> My church group is 100% within their right to kick me out of teaching
> Sunday School if I were to have an affair. Teaching Sunday School is an act
> taking place as part of a community of people with a shared belief and
> culture. My job would 100% not be within their right to fire me for having
> an affair, as it's not a community, but a professional environment and my
> personal life is just that: personal. (Baring an ethics clauses signed when
> joining, I guess?)
>

> Jim
>
>
> On Fri, Sep 14, 2018 at 10:31 AM, Ilya Kosmodemiansky 
> wrote:
>
>>
>>
>> On 14. Sep 2018, at 16:17, Dave Page  wrote:
>>
>>
>> The lists are just one of many different ways people in this community
>> interact.
>>
>>
>> I could only heavily +1 this. I can get from where comes the idea that
>> community is only what happens just on postgresql.org or just on some
>> other channel community uses. Community is people who joined it and CoC
>> supposed to apply even if people use analogue telephones. This is about
>> communication, not about communication channels.
>>
>>
>>
>> --
>> Dave Page
>> Blog: http://pgsnake.blogspot.com
>> Twitter: @pgsnake
>>
>> EnterpriseDB UK: http://www.enterprisedb.com
>> The Enterprise PostgreSQL Company
>>
>>
>


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

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


Re: Code of Conduct plan

2018-09-14 Thread Dave Page
On Fri, Sep 14, 2018 at 3:43 PM, Joshua D. Drake 
wrote:

> On 09/14/2018 07:36 AM, Dave Page wrote:
>
>
>
> On Fri, Sep 14, 2018 at 3:21 PM, James Keener  wrote:
>
>>
>> Now, you may say that (2) would be rejected by the committee, but I would
>>>> counter that it's still a stain on me and something that will forever
>>>> appear
>>>> along side my name in search results and that the amount of time and
>>>> stress it'd take me to defend myself would make my voluntarily leaving
>>>> the community, which would be seen as an admission of guilt, my only
>>>> option.
>>>>
>>>
>>> If you had read the policy, you would know that wouldn't happen as
>>> reports and details of reports are to be kept confidential.
>>>
>>
>> That doesn't mean I won't be strung along and it doesn't mean that the
>> attacker can't release those details. Remember, I'm worried
>> about politically motivated attacks, and attacks meant to silence
>> opposing viewpoints, not legitimate instances of harassment.
>>
>
> Sure, but an attacker can do that now. Having the CoC doesn't change
> anything there, though it does give us a framework to deal with it.
>
>
>>
>>
>>>
>>>
>>>>
>>>> People are shitheads. People are assholes. We're not agreeing to join
>>>> some organization and sign an ethics clause when signing up for the
>>>> mailing
>>>> list.  The current moderators can already remove bad actors from the
>>>> list.
>>>> How they act outside of the list is non of this list's concern.
>>>>
>>>
>>> The lists are just one of many different ways people in this community
>>> interact.
>>>
>>
>> So? We interact with people outside of specific groups all the time.
>> Baring specific
>> agreements to the contrary, why should any one group claim responsibility
>> of my
>> personal business?
>>
>
> If that business is publicly bringing the project into disrepute, or
> harassing other community members and they approach us about it, then it
> becomes our business.
>
> If it's unrelated to PostgreSQL, then it's your personal business and not
> something the project would get involved in.
>
>
> O.k. so this isn't clear (at least to me) within the CoC. I want to make
> sure I understand. You are saying that if a community member posts on
> Twitter that they believe gays are going to hell, reporting that to the CoC
> committee would result in a non-violation UNLESS they referenced postgresql
> within the post?
>

Yes, I believe so. Isn't that what "To that end, we have established this Code
of Conduct for community interaction and participation in the project’s
work and the community at large." basically says?

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

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


Re: Code of Conduct plan

2018-09-14 Thread Dave Page
On Fri, Sep 14, 2018 at 3:55 PM, James Keener  wrote:

>
>
> Yes. They can. The people who make the majority of the contributions to
>> the software can decide what happens, because without them there is no
>> software. If you want to spend 20 years of your life
>>
>
> So everyone who moderates this group and that will be part of the CoC
> committee will have had to have dedicated their life of pg?
>
> Sure, they own the servers, they make the rules. I get it. I'm not
> entirely opposed to it, even if I think it's silly to ram something down
> the rest of the groups throats.
>
> Jim
>
> PS: Also, what's with the personal replies? If you don't want to say what
> you want to the whole group, I don't really have an interest in talking to
> you personally.
>

I've had one off-list personal reply in this thread... from you :-p

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

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


Re: Code of Conduct plan

2018-09-14 Thread Dave Page
On Fri, Sep 14, 2018 at 3:57 PM, James Keener  wrote:

>
>
>> Yes, I believe so. Isn't that what "To that end, we have established
>> this Code of Conduct for community interaction and participation in the
>> project’s work and the community at large." basically says?
>>
>
> No? What's the "community at large"? To me that sounds like "all
> interactions" whether or not they're about postgres.
>

That wording has been in the published draft for 18 months, and noone
objected to it that I'm aware of. There will always be people who don't
like some of the wording, much as there are often people who disagree with
the way a patch to the code is written. Sooner or later though, the general
consensus prevails and we have to move on, otherwise nothing will ever get
completed.

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

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


Re: Code of Conduct plan

2018-09-14 Thread Dave Page
On Fri, Sep 14, 2018 at 3:10 PM, James Keener  wrote:

> I understand the concern, however, if you look at how attacks happen
>
>> it is frequently through other sites. Specifically under/poorly
>> moderated sites. For specific examples, people who have issues with
>> people on Quora will frequently go after them on Facebook and Twitter.
>>
>> these aren't a solution looking for a problem. If we just want to look
>> at the clusterfuck that is happening in the reddis community right now
>> we can see conversations spilling onto twitter and into ad hominem
>> vitriol.
>>
>
> You haven't established that this is both 1) the PG mailing list's problem
> and that 2) this can't and won't be used to retaliate against those holding
> unpopular viewpoints but aren't specifically harassing anyone.
>
> Now, you may say that (2) would be rejected by the committee, but I would
> counter that it's still a stain on me and something that will forever
> appear
> along side my name in search results and that the amount of time and
> stress it'd take me to defend myself would make my voluntarily leaving
> the community, which would be seen as an admission of guilt, my only
> option.
>

If you had read the policy, you would know that wouldn't happen as reports
and details of reports are to be kept confidential.


>
> People are shitheads. People are assholes. We're not agreeing to join
> some organization and sign an ethics clause when signing up for the mailing
> list.  The current moderators can already remove bad actors from the list.
> How they act outside of the list is non of this list's concern.
>

The lists are just one of many different ways people in this community
interact.

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

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


Re: Code of Conduct plan

2018-09-14 Thread Dave Page
On Fri, Sep 14, 2018 at 3:37 PM, Joshua D. Drake 
wrote:

> On 09/14/2018 07:14 AM, Dave Page wrote:
>
>
>
> On Fri, Sep 14, 2018 at 3:08 PM, Joshua D. Drake 
> wrote:
>
>> On 09/14/2018 01:31 AM, Chris Travers wrote:
>>
>>
>> I apologize for the glacial slowness with which this has all been moving.
>>> The core team has now agreed to some revisions to the draft CoC based on
>>> the comments in this thread; see
>>>
>>> https://wiki.postgresql.org/wiki/Code_of_Conduct
>>>
>>> (That's the updated text, but you can use the diff tool on the page
>>> history tab to see the changes from the previous draft.)
>>>
>>
>> I really have to object to this addition:
>> "This Code is meant to cover all interaction between community members,
>> whether or not it takes place within postgresql.org infrastructure, so
>> long as there is not another Code of Conduct that takes precedence (such as
>> a conference's Code of Conduct)."
>>
>> That covers things like public twitter messages over live political
>> controversies which might not be personally directed.   At least if one is
>> going to go that route, one ought to *also* include a safe harbor for
>> non-personally-directed discussions of philosophy, social issues, and
>> politics.  Otherwise, I think this is asking for trouble.  See, for
>> example, what happened with Opalgate and how this could be seen to
>> encourage use of this to silence political controversies unrelated to
>> PostgreSQL.
>>
>>
>> I think this is a complicated issue. On the one hand, postgresql.org has
>> no business telling people how to act outside of postgresql.org. Full
>> stop.
>>
>
> I'm going to regret jumping in here, but...
>
> I disagree. If a community member decides to join forums for other
> software and then strongly promotes PostgreSQL to the point that they
> become abusive or offensive to people making other software choices, then
> they are clearly bringing the project into disrepute and we should have
> every right to sanction them by preventing them participating in our
> project in whatever ways are deemed appropriate.
>
>
> We all know that PostgreSQL is the only database we should use and anybody
> using a different one just hasn't been enlightened yet. :P
>
> I think we need to define community member. I absolutely see your point of
> the individual is a contributor but community member is rather ethereal in
> this context don't you think?
>

There are some fuzzy edges I guess (e.g. Slack), but in my mind it's always
been anyone who participates in any of the projects communications channels.


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

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


Code of Conduct

2018-09-18 Thread Dave Page
The PostgreSQL Core team are pleased to announce that following a long
consultation process, the project’s Code of Conduct (CoC) has now been
finalised and published at https://www.postgresql.org/about/policies/coc/.

Please take time to read and understand the CoC, which is intended to
ensure that PostgreSQL remains an open and enjoyable project for anyone to
join and participate in.

A Code of Conduct Committee has been formed to handle any complaints. This
consists of the following volunteers:

- Stacey Haysler (Chair)
- Lætitia Avrot
- Vik Fearing
- Jonathan Katz
- Ilya Kosmodemiansky

We would like to extend our thanks and gratitude to Stacey Haysler for her
patience and expertise in helping develop the Code of Conduct, forming the
committee and guiding the work to completion.

-- 
Dave Page
PostgreSQL Core Team
http://www.postgresql.org/
<http://www.postgresql.org/>


Re: Windows installation problem at post-install step

2024-07-22 Thread Dave Page
Hi

On Mon, Jul 22, 2024 at 1:02 PM Sandeep Thakkar <
sandeep.thak...@enterprisedb.com> wrote:

>
>
> On Mon, Jul 22, 2024 at 5:21 PM Sandeep Thakkar <
> sandeep.thak...@enterprisedb.com> wrote:
>
>> Hi,
>>
>> EDB's windows installer gets the locales on the system using the
>> https://github.com/EnterpriseDB/edb-installers/blob/REL-16/server/scripts/windows/getlocales/getlocales.cpp
>>  and
>> then substitute some patterns (
>> https://github.com/EnterpriseDB/edb-installers/blob/REL-16/server/pgserver.xml.in#L2850)
>> I'm not sure why we do that but that is the old code and probably @Dave
>> Page   may know but I'm not sure if that
>> piece of code is responsible for this change in encoding in this case.
>>
>
It was to work around limitations in the way we could return data from an
external program to BitRock InstallBuilder. I forget the precise details as
it was something like 15 years ago, but essentially BitRock couldn't read
output that contained (certain?) non-alphanumeric characters, so I had to
do that crazy encode/decode dance.


>
>> When I checked the installation log shared by Ertan, I do see that the
>> locale passed to initcluster script is the same as returned by the
>> getlocales executable.
>>
>> Executing C:\Windows\System32\cscript //NoLogo "C:\Program
>> Files\PostgreSQL\16/installer/server/initcluster.vbs" "NT
>> AUTHORITY\NetworkService" "postgres" ""
>> "C:\Users\User1\AppData\Local\Temp/postgresql_installer_cd79fad8b7"
>> "C:\Program Files\PostgreSQL\16" "C:\DATA_PG16" 5432 "Turkish,Türkiye" 0
>>
>> Apology about the top posting. Please ignore this thread. I've replied to
> another thread.
>
>
>> On Mon, Jul 22, 2024 at 6:43 AM Thomas Munro 
>> wrote:
>>
>>> On Mon, Jul 22, 2024 at 11:58 AM Ertan Küçükoglu
>>>  wrote:
>>> > Thomas Munro , 21 Tem 2024 Paz, 23:27
>>> tarihinde şunu yazdı:
>>> >> 2.  Some existing database clusters which had been installed with the
>>> >> name "Turkish_Turkey.1254" became unstartable when the OS upgrade
>>> >> renamed that locale to "Turkish_Türkiye.1254".  I'm trying to provide
>>> >> a pathway[2] to fix such systems in core PostgreSQL in the next minor
>>> >> release.  Everyone affected probably already found another way but at
>>> >> least next time a country is renamed this might help with the next
>>> >> point too.
>>> >
>>> > I was also hit by that OS update.
>>> > There is a Microsoft tool for creating a locale installer
>>> > https://www.microsoft.com/en-us/download/details.aspx?id=41158
>>> > Using that tool and adding a second locale Turkish_Turkey.1254 (name
>>> before Microsoft update) in the OS can fix your broken PostgreSQL.
>>> > I believe most people simply choose this path.
>>> > There are also several blogs/articles written in Turkish about the
>>> problem.
>>>
>>> If that's easy and good enough then maybe I should abandon that
>>> on-the-fly renaming patch and we should just do a little documentation
>>> note...
>>>
>>> >> 3.  I'd also like to teach initdb to use BCP47 names like "tr-TR"
>>> >> instead of those names by default (ie if you don't specify a locale
>>> >> name explicitly), and have proposed that before[3] but it hasn't gone
>>> >> in due to lack of testing/reviews from Windows users.  It seems like
>>> >> that doesn't matter much in practice to all the people using the
>>> >> popular EDB installer, since it apparently takes control of picking
>>> >> the locale and explicitly passes it in (and screws up the encoding as
>>> >> we have now learned).
>>> >
>>> > If I am not mistaken BCP47 names are already used in Linux systems.
>>> > Using them would make PostgreSQL use the same locale names across
>>> Linux and Windows systems.
>>>
>>> Not exactly.  POSIX systems use
>>> [language[_territory][.codeset][@modifier]], but POSIX doesn't say
>>> what any of those components are[1] (are they ISO country codes?
>>> English words?  Hieroglyphs?), so, curiously, those Windows names like
>>> "English_United States.1252" are probably POSIX-conforming.  Every
>>> real POSIX system of course uses ISO language and country codes these
>>> days (tho

Re: Windows installation problem at post-install step

2024-07-23 Thread Dave Page
On Tue, Jul 23, 2024 at 1:27 AM Thomas Munro  wrote:

> On Mon, Jul 22, 2024 at 11:51 PM Sandeep Thakkar
>  wrote:
> > EDB's windows installer gets the locales on the system using the
> https://github.com/EnterpriseDB/edb-installers/blob/REL-16/server/scripts/windows/getlocales/getlocales.cpp
> and then substitute some patterns (
> https://github.com/EnterpriseDB/edb-installers/blob/REL-16/server/pgserver.xml.in#L2850)
> I'm not sure why we do that but that is the old code and probably @Dave
> Page  may know but I'm not sure if that piece of code is responsible for
> this change in encoding in this case.
>
> Ah, so it's calling EnumSystemLocales().  Interestingly, the
> documentation for that function says:
>
> "Note  For interoperability reasons, the application should prefer the
> EnumSystemLocalesEx function to EnumSystemLocales because Microsoft is
> migrating toward the use of locale names instead of locale identifiers
> for new locales. Any application that will be run only on Windows
> Vista and later should use EnumSystemLocalesEx."
>
> That seems to be talking about this exact issue, that we're supposed
> to be using "locale names".  I'm a little confused about the
> terminology for the various types of names and identifiers but if you
> follow the link to a example program[1] you can see that it's talking
> about the BCP47 "en-US" kind, that we want.  (That quote makes it
> sound like a new thing, but Vista came out ~17 years ago.)
>

Vista is when they added support for BCP47, but of course, back when that
code was written we were primarily supporting older versions of Windows
still, back to Windows 2000 iirc.


>
> So one idea would be that in v18, we not only change initdb.exe to
> pick a BCP47 locale name by default as I proposed in that other
> thread[2], but also in the v18 version of the EDB installer you
> consider switching that code over to EnumSystemLocalesEx().  Then we
> can start to kiss goodbye to the bad old names.  People would still
> propagate them into the future with pg_upgrade I guess, and it'd be up
> to users to replace them by updating their catalogs manually.  Does
> that make sense?
>

Yes, it does (spitballing: might be nice if we could automatically update
the catalogs as well).

-- 
Dave Page
VP, Chief Architect, Database Infrastructure
EDB: https://www.enterprisedb.com