zipf_test.sql
application/x-sql
Filename: zipf_test.sql
Type: application/x-sql
Part: 2
\set i random_zipfian(1, 10, 2.5) INSERT INTO zipf(i, cnt) VALUES (:i, 1) ON CONFLICT ON CONSTRAINT zipf_pkey DO UPDATE SET cnt = zipf.cnt + 1 WHERE EXCLUDED.i = :i;