Skip to main content
PostgreSQL

Less than 1 minutePostgreSQLsqldbpostgrespostgresql
CLI



Less than 1 minutePostgreSQLCLIclishpostgresddldmlsql-privilege
Query

A. 유용한 쿼리

A3. DML

A3-i. UPSERT문

INSERT INTO :테이블명 (
    :컬럼명1, :컬럼명2, :컬럼명3 /* ...[이하생략] */
) VALUES (
    :컬럼1의값, :컬럼2의값, :컬럼3의값 /* ...[이하생략] */
) ON CONFLICT (:index컬럼명1, :index컬럼명2 /* ...[이하생략] */) DO UPDATE SET
    :컬럼명1 = :컬럼1의값
    , :컬럼명2 = :컬럼2의값
    , :컬럼명3 = :컬럼3의값
    /* ...[이하생략] */
;

Less than 1 minutePostgreSQLQuerysqldbpostgrespostgresqlddldmlsql-privilege
References


About 4 minPostgreSQLReferencessqldbpostgres
Youtube


Less than 1 minutePostgreSQLYoutubesqldbpostgres
Article(s)

About 1 minPostgreSQLArticle(s)blogfreecodecamp.orgsqldbpostgrespostgresql