Skip to content

Fix SQL syntax that could cause deadlocks #2530

@harels

Description

@harels

/* SourceDao.upsert */ INSERT INTO sources (uuid, type, created_at, updated_at, name, connection_url ) VALUES ($1, $2, $3, $4, $5, $6) ON CONFLICT(name) DO UPDATE SET type = EXCLUDED.type, updated_at = EXCLUDED.updated_at, name = EXCLUDED.name, connection_url = EXCLUDED.connection_url RETURNING *
we should remove name = EXCLUDED.name since we know that it's the same name (because of the conflict)

Metadata

Metadata

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions