Re: [EXT] Re: SCROLLABLE/UPDATABLE cursor question

2023-04-24 Thread Garfield Lewis
Tom Lane writes: > Doesn't that work already? Hi Tom, This works perfectly well for a NON-UPDATABLE cursor: [lzsystem@nucky LZRDB-5220] $ psql -U lzpgsupr -d wdbs -f curs.pgs -e BEGIN; BEGIN CREATE TABLE t0(c0 int); psql:curs.pgs:2: NOTICE: DDL was performed without updating catalog table

Re: [EXT] Re: SCROLLABLE/UPDATABLE cursor question

2023-04-24 Thread Adrian Klaver
On 4/24/23 08:25, Garfield Lewis wrote: Tom Lane writes: > Doesn't that work already? Hi Tom, [sysprog@nucky workspace] (h-master-LZRDB-5220-fix-WCOC-failure)*$ psql -V psql (PostgreSQL) 14.7 Is this allowed maybe in Postgres 15? This: psql:curs.pgs:2: NOTICE: DDL was performed wit

what happens if a failed transaction is not rolled back?

2023-04-24 Thread Siddharth Jain
Hi All, i understand when writing application code, we should rollback a transaction that fails to commit. this is typically done in the catch block of a try-catch exception handler. but what if the developer does not rollback the transaction? what happens in that case? note that i am not asking:

Re: [EXT] Re: SCROLLABLE/UPDATABLE cursor question

2023-04-24 Thread Tom Lane
Garfield Lewis writes: > DECLARE cur0 SCROLL CURSOR FOR SELECT * FROM t0 FOR UPDATE; > psql:curs.pgs:4: ERROR: DECLARE SCROLL CURSOR ... FOR UPDATE is not supported > DETAIL: Scrollable cursors must be READ ONLY. Ah. Yeah, I don't think anyone is contemplating changing that. Scrollable cursors

Re: what happens if a failed transaction is not rolled back?

2023-04-24 Thread Adrian Klaver
On 4/24/23 08:37, Siddharth Jain wrote: Hi All, i understand when writing application code, we should rollback a transaction that fails to commit. this is typically done in the catch block of a try-catch exception handler. but what if the developer does not rollback the transaction? what happ

Re: what happens if a failed transaction is not rolled back?

2023-04-24 Thread Adrian Klaver
On 4/24/23 08:43, Adrian Klaver wrote: On 4/24/23 08:37, Siddharth Jain wrote: Hi All, i understand when writing application code, we should rollback a transaction that fails to commit. this is typically done in the catch block of a try-catch exception handler. but what if the developer does

Re: what happens if a failed transaction is not rolled back?

2023-04-24 Thread David G. Johnston
On Mon, Apr 24, 2023 at 8:37 AM Siddharth Jain wrote: > Hi All, > > i understand when writing application code, we should rollback a > transaction that fails to commit. this is typically done in the catch block > of a try-catch exception handler. but what if the developer does not > rollback the

Re: [EXT] Re: SCROLLABLE/UPDATABLE cursor question

2023-04-24 Thread Garfield Lewis
> Adrian Klaver mailto:adrian.kla...@aklaver.com>> > wrote: > This: > psql:curs.pgs:2: NOTICE: DDL was performed without updating catalog > tables: Note that CREATE TABLE from a non-SDM client does not maintain > LzRelational catalog tables > seems to indicate you are using some sort of Post

Re: [EXT] Re: SCROLLABLE/UPDATABLE cursor question

2023-04-24 Thread Garfield Lewis
> Garfield Lewis mailto:garfield.le...@lzlabs.com>> > wrote: > This is not a fork… it is pure Postgres 14 with an extension that checks for > a certain environment and reports a NOTICE otherwise. Oops, said extension meant trigger… -- Regards, Garfield A. Lewis

Re: what happens if a failed transaction is not rolled back?

2023-04-24 Thread Luca Ferrari
On Mon, Apr 24, 2023 at 5:37 PM Siddharth Jain wrote: > i am asking: what happens if a failed transaction is not rolled back? A transaction either terminates by a commit or by a rollback. A failed transaction is an opened transaction that can be terminated only by a rollback. If you don't rollbac

Re: what happens if a failed transaction is not rolled back?

2023-04-24 Thread David Wheeler
> On 25 Apr 2023, at 1:47 am, David G. Johnston > wrote: > > There isn't anything special about a failed transaction compared to any other > transaction that you leave open. Now I’m curious. Does it have the same impact on performance that an idle in transaction connection has? Eg does it p

Re: what happens if a failed transaction is not rolled back?

2023-04-24 Thread David G. Johnston
On Mon, Apr 24, 2023 at 12:56 PM David Wheeler wrote: > > > On 25 Apr 2023, at 1:47 am, David G. Johnston > wrote: > > > There isn't anything special about a failed transaction compared to any > other transaction that you leave open. > > > Now I’m curious. Does it have the same impact on perform

Re: what happens if a failed transaction is not rolled back?

2023-04-24 Thread Tom Lane
"David G. Johnston" writes: > On Mon, Apr 24, 2023 at 12:56 PM David Wheeler > wrote: >> Now I’m curious. Does it have the same impact on performance that an idle >> in transaction connection has? Eg does it prevent vacuum? Does it still >> hold locks? > Absent documentation to the contrary I wo

RE: FW: Error!

2023-04-24 Thread Arquimedes Aguirre
Hi Dear Ok thanks so much for the explanation, but I don't understand, what does that connection have to do with the error that I described at the beginning, it gives me a password error with any user, what should I do to solve this problem and be able to start the connection?. I would like to

Re: FW: Error!

2023-04-24 Thread Adrian Klaver
On 4/24/23 15:00, Arquimedes Aguirre wrote: Hi Dear Ok thanks so much for the explanation, but I don't understand, what does that connection have to do with the error that I described at the beginning, it gives me a password error with any user, what should I do to solve this problem and be a

RE: FW: Error!

2023-04-24 Thread Arquimedes Aguirre
No, it has not changed the error that I have been experiencing since the beginning. This is the error: psql: error: connection to server at "localhost" (::1), port 5432 failed: FATAL: password authentication failed for user "punta" Press any key to continue . . Has always been the same error

Re: FW: Error!

2023-04-24 Thread Adrian Klaver
On 4/24/23 16:16, Arquimedes Aguirre wrote: No, it has not changed the error that I have been experiencing since the beginning. This is the error: psql: error: connection to server at "localhost" (::1), port 5432 failed: FATAL: password authentication failed for user "punta" Press any key to

Re: FW: Error!

2023-04-24 Thread Erik Wienhold
> On 25/04/2023 01:34 CEST Adrian Klaver wrote: > > On 4/24/23 16:16, Arquimedes Aguirre wrote: > > I got question, because can’t you send a screenshots, with the image > > it’s much easier to identify the error or problem and you can also read > > the message, I don’t understand? > > Many folks o

Re: what happens if a failed transaction is not rolled back?

2023-04-24 Thread Merlin Moncure
On Mon, Apr 24, 2023 at 4:20 PM Tom Lane wrote: > "David G. Johnston" writes: > > On Mon, Apr 24, 2023 at 12:56 PM David Wheeler > > wrote: > >> Now I’m curious. Does it have the same impact on performance that an > idle > >> in transaction connection has? Eg does it prevent vacuum? Does it sti

murmur3 hash binary data migration from Oracle to PostgreSQL

2023-04-24 Thread Jagmohan Kaintura
Hi Team, We are doing Migration from Oracle to PostgreSQL. In SOurce database we have Binary data stored using murmur3 hashing function. In Oracle this data is being generated from the Java code and inserted into the Oracle database. As part of Migration processes the reference data on which this

Re: what happens if a failed transaction is not rolled back?

2023-04-24 Thread Tom Lane
Merlin Moncure writes: > Hm. I also noticed when looking at this that aborted transactions with > savepoints are not subjected to the idle_in_transaction timeout which is a > bit surprising. Hmm ... I think it's intentional that idle_in_transaction no longer applies once the transaction has faile

Re: what happens if a failed transaction is not rolled back?

2023-04-24 Thread Merlin Moncure
On Mon, Apr 24, 2023 at 8:41 PM Tom Lane wrote: > Merlin Moncure writes: > > Hm. I also noticed when looking at this that aborted transactions with > > savepoints are not subjected to the idle_in_transaction timeout which is > a > > bit surprising. > > Hmm ... I think it's intentional that idle_

wiki.postgres ​ Tighten trigger permission checks already resolved

2023-04-24 Thread jian he
Hi. The following Todo item seems already resolved in pg15. https://wiki.postgresql.org/wiki/Todo#Triggers > Tighten trigger permission checks > >- Security leak with trigger functions? > > > But it seems to not appear i

Re: murmur3 hash binary data migration from Oracle to PostgreSQL

2023-04-24 Thread Erik Wienhold
> On 25/04/2023 03:21 CEST Jagmohan Kaintura wrote: > > We are doing Migration from Oracle to PostgreSQL. In SOurce database we have > Binary data stored using murmur3 hashing function. In Oracle this data is > being generated from the Java code and inserted into the Oracle database. Do you store

Re: wiki.postgres ​ Tighten trigger permission checks already resolved

2023-04-24 Thread Tom Lane
jian he writes: > The following Todo item seems already resolved in pg15. > https://wiki.postgresql.org/wiki/Todo#Triggers >> Tighten trigger permission checks >> - Security leak with trigger functions? >> > But it seems to not

Re: murmur3 hash binary data migration from Oracle to PostgreSQL

2023-04-24 Thread Jeffrey Walton
On Mon, Apr 24, 2023 at 9:22 PM Jagmohan Kaintura wrote: > > We are doing Migration from Oracle to PostgreSQL. In SOurce database we have > Binary data stored using murmur3 hashing function. In Oracle this data is > being generated from the Java code and inserted into the Oracle database. > > As