Re: Copy & Re-copy of DB

2021-01-21 Thread Ken Tanzer
On Thu, Jan 21, 2021 at 11:12 PM sivapostg...@yahoo.com < sivapostg...@yahoo.com> wrote: > So the solution to the issue will be > > 1. Backup a DB using PGDUMP from 1st server. > 2. Restore the DB in 2nd server. > 3. Make required changes in the 2nd server. > 4. Backup that DB using PGDUMP fro

Re: Copy & Re-copy of DB

2021-01-21 Thread sivapostg...@yahoo.com
So the solution to the issue will be 1.  Backup a DB using PGDUMP from 1st server.2.  Restore the DB in 2nd server.3.  Make required changes in the 2nd server.4.  Backup that DB using PGDUMP from 2nd server.5.  Delete / Rename that DB in the 1st server6.  Restore that DB in the 1st server.7.  W

FDW connections

2021-01-21 Thread Steve Baldwin
Hi all, If I have made a query on a foreign table (using postgres_fdw), it establishes a connection automatically. Is there any way to disconnect that fdw connection without disconnecting the session that instigated it? Thanks, Steve

Re: Customer unable to connect on port 5432, Postgres 10.7

2021-01-21 Thread Adrian Klaver
On 1/21/21 5:30 PM, Keith Christian wrote: Hello again Postgres friends, Customer is unable to log in to a PG database on 5432 using a Windows client. Output of my test sessions below, I think the problem may be lines 3 - 7 but no idea. Ideas greatly appreciated! Lines 1,2 PG Log entries Lines

Re: Customer unable to connect on port 5432, Postgres 10.7

2021-01-21 Thread Ron
On 1/21/21 7:30 PM, Keith Christian wrote: Hello again Postgres friends, Customer is unable to log in to a PG database on 5432 using a Windows client. Output of my test sessions below, I think the problem may be lines 3 - 7 but no idea. Ideas greatly appreciated! Lines 1,2 PG Log entries Lines

Customer unable to connect on port 5432, Postgres 10.7

2021-01-21 Thread Keith Christian
Hello again Postgres friends, Customer is unable to log in to a PG database on 5432 using a Windows client. Output of my test sessions below, I think the problem may be lines 3 - 7 but no idea. Ideas greatly appreciated! Lines 1,2 PG Log entries Lines 3-7 pg_hba.conf entries Lines 8-10 postgresq

Re: interval data type

2021-01-21 Thread Christophe Pettus
> On Jan 21, 2021, at 13:22, James B. Byrne wrote: > > What is the difference between interval(3)[] and simply interval(3)? Where in > the documentation is the [] syntax discussed? The [] syntax means an array. For example, float[] means an array of floating point numbers, so interval[] me

Re: interval data type

2021-01-21 Thread Thomas Kellerer
James B. Byrne schrieb am 21.01.2021 um 22:22: What is the difference between interval(3)[] and simply interval(3)? Where in the documentation is the [] syntax discussed? The [] denotes an array of intervals. So in a column defined as interval[] you can store multiple intervals, just like in

Re: autovacuum verbose?

2021-01-21 Thread Peter Geoghegan
On Thu, Jan 21, 2021 at 12:55 PM Tommy Li wrote: > Is there any way to configure autovacuum to log the same information as > VACUUM VERBOSE? No. Though there really should be. -- Peter Geoghegan

interval data type

2021-01-21 Thread James B. Byrne
What is the difference between interval(3)[] and simply interval(3)? Where in the documentation is the [] syntax discussed? This question arises only because I am trying to map an Informix database column defined as lead_time INTERVAL DAY(3) TO DAY to an equivalent PostgreSQL datatype. I g

Re: Error while running restore

2021-01-21 Thread Adrian Klaver
On 1/21/21 9:52 AM, Márcio Antônio Sepp wrote: Hi all, I’m getting this error message when try to restore a database : ERROR:  function f_validanumero_cnpj_cpf(character) does not exist LINE 1: SELECT (f_validanumero_cnpj_cpf(trim(cnpj_cpf)::char)=false)     ^ HINT:  No function

autovacuum verbose?

2021-01-21 Thread Tommy Li
Hi all Is there any way to configure autovacuum to log the same information as VACUUM VERBOSE? My understanding is that the autovacuum workers just run the VACUUM command, so can they be configured to accept the same options? Thanks, Tommy

Re: Copy & Re-copy of DB

2021-01-21 Thread Ken Tanzer
On Thu, Jan 21, 2021 at 5:52 AM sivapostg...@yahoo.com < sivapostg...@yahoo.com> wrote: > create database is to create a new database. If we switch to new > database, we need to change the new databasename in the program(s) that > access this database. > > If you are just concerned about having t

Re: Error while running restore

2021-01-21 Thread Tom Lane
=?iso-8859-1?Q?M=E1rcio_Ant=F4nio_Sepp?= writes: > I’m getting this error message when try to restore a database : > ERROR: function f_validanumero_cnpj_cpf(character) does not exist > LINE 1: SELECT (f_validanumero_cnpj_cpf(trim(cnpj_cpf)::char)=false) > ^ > HINT: No function ma

RES: Error while running restore

2021-01-21 Thread Márcio Antônio Sepp
Ops, Server version tested are: PostgreSQL 11.5 and PostgreSQL 13.1 In both cases, i’m making dump and restore to the same Server. -- Att Márcio A. Sepp De: Márcio Antônio Sepp [mailto:mar...@zyontecnologia.com.br] Enviada em: quinta-feira, 21 de janeiro de 2021 14:53 Para:

Error while running restore

2021-01-21 Thread Márcio Antônio Sepp
Hi all, I’m getting this error message when try to restore a database : ERROR: function f_validanumero_cnpj_cpf(character) does not exist LINE 1: SELECT (f_validanumero_cnpj_cpf(trim(cnpj_cpf)::char)=false) ^ HINT: No function matches the given name and argument t

Re: Copy & Re-copy of DB

2021-01-21 Thread Benedict Holland
Pg_dump and pg_restore are what you want. They create sql files that you pass around. But seriously, if you have two servers running, replicate one or have your application point to a server address that you can direct via dns to whatever active one you want. Postgres makes replication simple. The

Re: Copy & Re-copy of DB

2021-01-21 Thread sivapostg...@yahoo.com
create database is to create a new database.  If we switch to new database, we need to change the new databasename in the program(s) that access this database.   Is there any way to overwrite the data ? On Thursday, 21 January, 2021, 07:12:19 pm IST, Ray O'Donnell wrote: On 21/01/202

Re: Copy & Re-copy of DB

2021-01-21 Thread Benedict Holland
Pg_dump does what you want but you could also set up replication. Thanks, Ben On Thu, Jan 21, 2021, 8:42 AM Ray O'Donnell wrote: > On 21/01/2021 13:13, sivapostg...@yahoo.com wrote: > > Hello, > > > > I'm from SQL Server now developing my current project using PG. > > > > In our earlier project

Re: Copy & Re-copy of DB

2021-01-21 Thread Ray O'Donnell
On 21/01/2021 13:13, sivapostg...@yahoo.com wrote: Hello, I'm from SQL Server now developing my current project using PG. In our earlier project(s), we used to copy the database from one server to another, work in another server, and re-copy it in the original server.   All happened easily wi

Re: Copy & Re-copy of DB

2021-01-21 Thread Ravi Krishna
In SQLServer each db has its own data file and transaction log file and hence can be copied the way you described. > Limitation of Backup utility. Transfer to another server was done > successfully. When we want to re-copy to original server, >we have to delete the original db in the original se

Re: Copy & Re-copy of DB

2021-01-21 Thread sivapostg...@yahoo.com
Hello, I'm from SQL Server now developing my current project using PG. In our earlier project(s), we used to copy the database from one server to another, work in another server, and re-copy it in the original server.   All happened easily with just transferring the two files (mdf & ldf) to our

Re: See what options a Postgresql binary was compiled with

2021-01-21 Thread Laurenz Albe
On Wed, 2021-01-20 at 17:27 -0700, Keith Christian wrote: > Planning to convert a Postgres 10 instance to systemd init. > I understand it had to be compiled with systemd support to work that way. That is only necessary if you want to start the service with "Type=notify". If you start it using "T

Re: pljava": ERROR

2021-01-21 Thread Magnus Hagander
On Thu, Jan 21, 2021 at 9:04 AM Atul Kumar wrote: > > Hi, > > When I was trying to upgrade from postgres 9.5 to postgres 10 using command > su - enterprisedb/usr/edb/as10/bin/pg_upgrade -d > /data/apps/ppas/9.5/data -D /data/edb/as10/data -U enterprisedb -b > /usr/ppas-9.5/bin/ -B /usr/edb/as10

pljava": ERROR

2021-01-21 Thread Atul Kumar
Hi, When I was trying to upgrade from postgres 9.5 to postgres 10 using command su - enterprisedb/usr/edb/as10/bin/pg_upgrade -d /data/apps/ppas/9.5/data -D /data/edb/as10/data -U enterprisedb -b /usr/ppas-9.5/bin/ -B /usr/edb/as10/bin/ -p 5444 -P 5445 --check I got below error: could not load