void appendOnConflictClause(StringBuilder sb) {
        sb.append("ON CONFLICT ");
        appendFieldNames(sb, jdbcTable.getPrimaryKeyList());
        sb.append(" DO UPDATE SET ");

        Iterator<String> it = jdbcTable.dbFieldNames().iterator();
        while (it.hasNext()) {
            String dbFieldName = it.next();
            dialect.quoteIdentifier(sb, dbFieldName);
            sb.append(" = EXCLUDED.");
            dialect.quoteIdentifier(sb, dbFieldName);
            if (it.hasNext()) {
                sb.append(',');
            }
        }
    }
@Test
    void testAppendOnConflictClause() {
        PostgresUpsertQueryBuilder builder = new PostgresUpsertQueryBuilder(jdbcTable, dialect);
        StringBuilder sb = new StringBuilder();
        builder.appendOnConflictClause(sb);

        String valuesClause = sb.toString();
        assertThat(valuesClause).isEqualTo(
                "ON CONFLICT (\"pk1\",\"pk2\") " +
                        "DO UPDATE SET " +
                        "\"field1\" = EXCLUDED.\"field1\"," +
                        "\"field2\" = EXCLUDED.\"field2\""
        );
    }