Re:Re: Different sort result between PostgreSQL 8.4 and 12.5

2022-06-27 Thread gzh
Dear Magnus: The information you sent through to me was perfect. After I checked the operating system, I found that they are really different. --PostgreSQL 8.4 LANG=ja_JP.UTF-8 --PostgreSQL 12.5 LANG=en_US.UTF-8 After I added the following syntax after the "order by ascid" in

Re: Libpq question related to allocated resources

2022-06-27 Thread Tom Lane
Karl Denninger writes: > But -- I still have a /lot /of memory out on the heap according to > jemalloc stats that is not being deallocated, and what's worse is that > if I rig the code to call PQfinish and then PQconnect once again I get > /even more /imbalanced allocate/free counts (and the

Re: Unique index prohibits partial aggregates

2022-06-27 Thread David Rowley
On Mon, 27 Jun 2022 at 23:49, Bos, Fred wrote: > "Settings: effective_cache_size = '128GB', force_parallel_mode = 'on', > max_parallel_workers = '40', You shouldn't be using force_parallel_mode. It does not do what you think. See the documentation for that GUC, or read [1] > I expected the

Re: Outer joins and NULLs (old subject "ERROR: failed to find conversion function from key_vals_nn to record[]")

2022-06-27 Thread Bryn Llewellyn
> david.g.johns...@gmail.com wrote: > > Allowing domains to be defined as not null at this point is simply something > that we don't support but don't error out upon in the interest of backward > compatibility. (IMO, the documentation is not this strongly worded.) It, as > you note, has some

Libpq question related to allocated resources

2022-06-27 Thread Karl Denninger
I've got a fairly sizeable application that runs as a CGI app under Apache which I am attempting to convert to FastCGI. "Once through and done" apps tend not to care much if deallocation is less than perfect, since exit(0) (or otherwise) tends to heal all wounds.  Not so much when something's

Re: Table space not returned to the OS ?

2022-06-27 Thread Magnus Hagander
On Mon, Jun 27, 2022 at 12:01 PM Laurenz Albe wrote: > On Mon, 2022-06-27 at 11:38 +0200, Magnus Hagander wrote: > > On Mon, Jun 27, 2022 at 11:30 AM Florents Tselai < > florents.tse...@gmail.com> wrote: > > > A few months back (October) I had upgraded a Postgres instance from > v12 —> 14. > > >

Re: Different sort result between PostgreSQL 8.4 and 12.5

2022-06-27 Thread Magnus Hagander
On Mon, Jun 27, 2022 at 1:31 PM gzh wrote: > Hi, > > > I have had a Perl Website working for 7 years and have had no problems > until a few weeks ago I replaced my database server with a newer one. > > > Database server (old): PostgreSQL 8.4 32bit > > Database server (new): PostgreSQL 12.5 64bit

Different sort result between PostgreSQL 8.4 and 12.5

2022-06-27 Thread gzh
Hi, I have had a Perl Website working for 7 years and have had no problems until a few weeks ago I replaced my database server with a newer one. Database server (old): PostgreSQL 8.4 32bit Database server (new): PostgreSQL 12.5 64bit I run following sql in PostgreSQL 8.4 and

Re: Differences in Escaped bytea's when creating a plain pg_dump

2022-06-27 Thread Wolfgang Rißler
Am 27.06.2022 um 12:12 schrieb Daniel Verite: WR wrote: First run worked. Second run worked. Then I changed to SET standard_conforming_strings = off; Third run worked. Fourth run throw the error Then I changed back to SET standard_conforming_strings = on; Fifth run throw the error

Re: Question about attention to pgsql-hack...@lists.postgresql.org

2022-06-27 Thread Imre Samu
>From the original post "-This whole system will uphold any precision, certainly ones within a very large range limit, controlled by the already available type for large positive integers, the BIGINT. It can thereby enumerate digits within the range of (+/-)1 to (+/-)9,223,372,036,854,775,807.

Re: help for pg_wal issue

2022-06-27 Thread Laurenz Albe
On Mon, 2022-06-27 at 09:50 +, Özge Özyavuz wrote: > I want to backup my postgresql database but it fails because it is looking > for some wal files on pg_wal directory. >   > Before backup I checked my pg_wal directory and I saw the wal file, >   > bash-4.2$ cd /pgdata/pgsql/data/pg_wal >

Re: Differences in Escaped bytea's when creating a plain pg_dump

2022-06-27 Thread Daniel Verite
WR wrote: > First run worked. > Second run worked. > Then I changed to SET standard_conforming_strings = off; > Third run worked. > Fourth run throw the error > Then I changed back to SET standard_conforming_strings = on; > Fifth run throw the error too. > And only adding E and second

help for pg_wal issue

2022-06-27 Thread Özge Özyavuz
Hi, I want to backup my postgresql database but it fails because it is looking for some wal files on pg_wal directory. Before backup I checked my pg_wal directory and I saw the wal file, bash-4.2$ cd /pgdata/pgsql/data/pg_wal bash-4.2$ ls -rw--- 1 postgres postgres 16777216 Jun 24 01:01

Re: Table space not returned to the OS ?

2022-06-27 Thread Laurenz Albe
On Mon, 2022-06-27 at 11:38 +0200, Magnus Hagander wrote: > On Mon, Jun 27, 2022 at 11:30 AM Florents Tselai > wrote: > > A few months back (October) I had upgraded a Postgres instance from v12 —> > > 14. > > > > The database disk size under /var/lib/postgresql/12 was around 800GB+ back > >

Re: Table space not returned to the OS ?

2022-06-27 Thread Florents Tselai
> On 27 Jun 2022, at 12:38 PM, Magnus Hagander wrote: > > > > On Mon, Jun 27, 2022 at 11:30 AM Florents Tselai > wrote: > Hi, > > A few months back (October) I had upgraded a Postgres instance from v12 —> 14. > > The database disk size under

Table space not returned to the OS ?

2022-06-27 Thread Florents Tselai
Hi, A few months back (October) I had upgraded a Postgres instance from v12 —> 14. The database disk size under /var/lib/postgresql/12 was around 800GB+ back then. Note, that IIRC I had used hard-linking during the upgrade. In the database itself, lots of things have changed since. In fact,

Re: Differences in Escaped bytea's when creating a plain pg_dump

2022-06-27 Thread Wolfgang Rißler
Am 27.06.2022 um 09:32 schrieb David G. Johnston: [snip] I suggest doing self-contained examples that demonstrate the documented behavior not working as documented (or not being functional even if intended) to pinpoint any bug that might be lurking here.  With only fragments and statements

Re: Table space not returned to the OS ?

2022-06-27 Thread Thomas Boussekey
Hello Florents, Le lun. 27 juin 2022 à 11:30, Florents Tselai a écrit : > Hi, > > A few months back (October) I had upgraded a Postgres instance from v12 —> > 14. > > The database disk size under /var/lib/postgresql/12 was around 800GB+ back > then. > Note, that IIRC I had used hard-linking

Re: Table space not returned to the OS ?

2022-06-27 Thread Magnus Hagander
On Mon, Jun 27, 2022 at 11:30 AM Florents Tselai wrote: > Hi, > > A few months back (October) I had upgraded a Postgres instance from v12 —> > 14. > > The database disk size under /var/lib/postgresql/12 was around 800GB+ back > then. > Note, that IIRC I had used hard-linking during the upgrade.

Re: Differences in Escaped bytea's when creating a plain pg_dump

2022-06-27 Thread David G. Johnston
On Sunday, June 26, 2022, WR wrote: > > I made some test with pgadmin. Pgadmin (5.2) also reports this error now. > And it doesn't matter if standard_conforming_strings is on or off. > > > SET standard_conforming_strings = off; > > INSERT INTO public.oned_figures VALUES (1, 'Figure_Wolle1', 476,

Re: Differences in Escaped bytea's when creating a plain pg_dump

2022-06-27 Thread WR
Another strange thing is: in my first mail I wrote: running the dump in in pgadmin works, in the last mail I wrote pgadmin also produces the error. I played a little bit how this could be happend. Everytime ich used the following sql text in the querytool: SET standard_conforming_strings =

Sv: How can I set up Postgres to use given amount of RAM?

2022-06-27 Thread Andreas Joseph Krogh
På søndag 26. juni 2022 kl. 20:40:01, skrev W.P. mailto:laure...@wp.pl>>: Question in topic: "How can I set up Postgres to use given amount of RAM?" I have now laptop with 8GB of RAM, i can see Linux uses no more than 2-3GB. So my question is how to FORCE PostgreSQL use let's say 2-4Ghow to

Re: Differences in Escaped bytea's when creating a plain pg_dump

2022-06-27 Thread WR
I'm back at my problem today: Example: postgres=# set standard_conforming_strings to off; SET postgres=# set escape_string_warning to off; SET postgres=# select '\000'::bytea; ERROR: invalid byte sequence for encoding "UTF8": 0x00 postgres=# select '\\000'::bytea; bytea ---