search for: upsert

Displaying 8 results from an estimated 8 matches for "upsert".

Did you mean: assert
2006 Aug 03
6
create or update -
Hi everyone, I''m looking for a shortcut to finding and updating or creating record depending on the results of the find. So, is there a shorter way to do it than this? @stuff = Stuff.find_by_foo_and_bar("yay","hooray") if @stuff: Stuff.update(@stuff.id, {:foo => "boo", :bar => "hoo"}) else Stuff.create({:foo => "boo",
2021 Aug 06
3
v2.3.16 released
...e files now and does not require specifying the binary path. + imapc: When imap_acl plugin is loaded and imapc_features=acl is used, IMAP ACL commands are proxied to the remote server. See https://doc.dovecot.org/configuration_manual/mail_location/imapc/ + dict-sql now supports the "UPSERT" syntax for SQLite and PostgreSQL. + imap: If IMAP client disconnects during a COPY command, the copying is aborted, and changes are reverted. This may help to avoid many email duplicates if client disconnects during COPY and retries it after reconnecting. - master process was using...
2021 Aug 06
3
v2.3.16 released
...e files now and does not require specifying the binary path. + imapc: When imap_acl plugin is loaded and imapc_features=acl is used, IMAP ACL commands are proxied to the remote server. See https://doc.dovecot.org/configuration_manual/mail_location/imapc/ + dict-sql now supports the "UPSERT" syntax for SQLite and PostgreSQL. + imap: If IMAP client disconnects during a COPY command, the copying is aborted, and changes are reverted. This may help to avoid many email duplicates if client disconnects during COPY and retries it after reconnecting. - master process was using...
2019 May 22
3
Dict issue with PostgreSQL for last_login plugin (duplicate key)
On 21/05/2019 15:45, mabi via dovecot wrote: > ??????? Original Message ??????? > On Monday, May 20, 2019 12:37 AM, John Fawcett via dovecot > <dovecot at dovecot.org> wrote: > >> So looking into this with a postgresql databse to work with: the >> above query does not work. You have to specify either the column name >> or the constraint name that you expect to
2019 May 23
0
more generic approach as for userdb? (was: Dict issue with PostgreSQL for last_login plugin (duplicate key))
...ded to the code, but closer inspection shows that the > PostgreSql syntax requires specification of either a constraint name or > the index column(s) for the primary/unique keys. You mean the "target" in ON CONFLICT target action, right? http://www.postgresqltutorial.com/postgresql-upsert/ > Constraint names are nowhere specified in the dictionary map syntax and > it's not possible either to identify with 100% certainty the primary key > column(s). One could dive into Postgres-specifics to get it, but there are other SQLs, too; the quota plugin advertises to use TRIG...
2019 May 28
0
Dict issue with PostgreSQL for last_login plugin (duplicate key)
...been quite some discussion how to make things more generic and better for database queries in general in Dovecot around my issue but I would still be very thankful if your original patch could be submitted to Dovecot for review and approval. Your patch solves an immediate problem which is of adding UPSERT functionality to PostgreSQL Dict queries. MySQL Dict queries has its "INSERT ... ON DUPLICATE KEY UPDATE" implemented in Dovecot so I think it's more than fair that for now that PostgreSQL support in Dict also gets its equivalent "INSERT ... ON CONFLICT UPDATE" implemented....
2019 May 29
2
Dict issue with PostgreSQL for last_login plugin (duplicate key)
...ussion how to make things more > generic and better for database queries in general in Dovecot around > my issue but I would still be very thankful if your original patch > could be submitted to Dovecot for review and approval. Your patch > solves an immediate problem which is of adding UPSERT functionality to > PostgreSQL Dict queries. > > MySQL Dict queries has its "INSERT ... ON DUPLICATE KEY UPDATE" > implemented in Dovecot so I think it's more than fair that for now > that PostgreSQL support in Dict also gets its equivalent "INSERT ... > ON CONFL...
2019 May 19
4
Dict issue with PostgreSQL for last_login plugin (duplicate key)
On 19/05/2019 22:45, John Fawcett via dovecot wrote: > On 19/05/2019 22:37, John Fawcett via dovecot wrote: >> On 19/05/2019 20:31, mabi via dovecot wrote: >>> >>> ??????? Original Message ??????? >>> On Sunday, May 19, 2019 7:36 PM, John Fawcett via dovecot >>> <dovecot at dovecot.org> wrote: >>>> >>>> Attached is a