mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2025-01-18 14:41:31 +08:00
use a compatible pg syntax for upsert
This commit is contained in:
parent
7f44d953b5
commit
9f1cab179c
@ -168,7 +168,7 @@ connection_max_idle = 100
|
|||||||
connection_max_open = 100
|
connection_max_open = 100
|
||||||
connection_max_lifetime_seconds = 0
|
connection_max_lifetime_seconds = 0
|
||||||
# if insert/upsert failing, you can disable upsert or update query syntax to match your RDBMS syntax:
|
# if insert/upsert failing, you can disable upsert or update query syntax to match your RDBMS syntax:
|
||||||
upsertQuery = """INSERT INTO "%[1]s" (dirhash,name,directory,meta) VALUES($1,$2,$3,$4) ON CONFLICT ON CONSTRAINT "%[1]s_pkey" DO UPDATE SET meta = EXCLUDED.meta WHERE "%[1]s".meta != EXCLUDED.meta"""
|
upsertQuery = """INSERT INTO "%[1]s" (dirhash,name,directory,meta) VALUES($1,$2,$3,$4) ON CONFLICT (dirhash,name) DO UPDATE SET meta = EXCLUDED.meta WHERE "%[1]s".meta != EXCLUDED.meta"""
|
||||||
enableUpsert = true
|
enableUpsert = true
|
||||||
|
|
||||||
[postgres2]
|
[postgres2]
|
||||||
|
Loading…
Reference in New Issue
Block a user