Include database collation in output

This commit is contained in:
Peter J. Holzer 2023-07-23 12:00:00 +02:00
parent 1d007a9e8e
commit a3a976908d
1 changed files with 3 additions and 0 deletions

View File

@ -6,6 +6,9 @@ db = psycopg2.connect("")
csr = db.cursor()
csr.execute("select version()")
for r in csr:
print(r[0])
csr.execute("select datcollate from pg_database where datname = current_database()")
for r in csr:
print(r[0])
csr.execute("drop table if exists t_pgcollate")