psycopg3: prepared statements

2020-12-21 Thread Daniele Varrazzo
Hello, I am gathering ideas about how to implement prepared statements in psycopg3. A plan is sketched at . Feedback is welcome, thank you very much! -- Daniele

Re: Avoid excessive inlining?

2020-12-21 Thread Philip Semanchuk
> On Dec 19, 2020, at 12:59 AM, Joel Jacobson wrote: > > Is there a way to avoid excessive inlining when writing pure SQL functions, > without having to use PL/pgSQL? Hi Joel, The rules for inlining are here: https://wiki.postgresql.org/wiki/Inlining_of_SQL_functions According to those rule

Re: Missing rows after migrating from postgres 11 to 12 with logical replication

2020-12-21 Thread Lars Vonk
Hi Adrian, Thanks for taking the time to reply! First to answer your questions: 1) Was there activity on the 12 instance while it was being replicated > to that could account for the missing(deleted?) rows? > No there was no activity other than us doing some queries to check how far the replica

pg_upgrade question

2020-12-21 Thread Lu, Dan
Hi PostgreSQL Admin, I am trying to find out if there is any step by step instruction to reconcile old data dir and upgraded data dir after using "-link" option to do an upgrade. I ran this to do an upgrade from 11.5 to 12.1: pg_upgrade -d /hostname/pg/dev115/data -D /hostname/pg/dev121upg/data

Re: Missing rows after migrating from postgres 11 to 12 with logical replication

2020-12-21 Thread Adrian Klaver
On 12/21/20 12:26 PM, Lars Vonk wrote: Hi Adrian, Thanks for taking the time to reply! 2) Are the logs still available for inspection to see if there where any errors thrown? Yes, and we dug into those. And we also found some indications that something went wrong. 4)

Re: Missing rows after migrating from postgres 11 to 12 with logical replication

2020-12-21 Thread Lars Vonk
> > What was being run when the above ERROR was triggered? The initial copy of a table. Other than that we ran select pg_size_pretty(pg_relation_size('table_name')) to see the current size of the table being copied to get a feeling on progress. And whenever we added a new table to the publicatio

Re: Missing rows after migrating from postgres 11 to 12 with logical replication

2020-12-21 Thread Adrian Klaver
On 12/21/20 2:42 PM, Lars Vonk wrote: What was being run when the above ERROR was triggered? The initial copy of a table. Other than that we ran select pg_size_pretty(pg_relation_size('table_name')) to see the current size of the table being copied to get a feeling on progress. And when

Access session level local params from another transaction by process id (PID)

2020-12-21 Thread Stanislav Mudrinski
Hi, I have a question regarding session params. We are using them thru SET LOCAL call request when connection is popped from pool to set, for example userId or API call route for current transaction so that any stored procedure can fetch them, if needed. This reduces number of params for eve