mirror of
https://github.com/psycopg/psycopg2.git
synced 2024-11-22 17:06:33 +03:00
Fixed DNS typo in examples
This commit is contained in:
parent
7b82be936d
commit
0258e90ef0
|
@ -24,7 +24,7 @@ import psycopg2
|
||||||
if len(sys.argv) > 1:
|
if len(sys.argv) > 1:
|
||||||
DSN = sys.argv[1]
|
DSN = sys.argv[1]
|
||||||
|
|
||||||
print "Opening connection using dns:", DSN
|
print "Opening connection using dsn:", DSN
|
||||||
conn = psycopg2.connect(DSN)
|
conn = psycopg2.connect(DSN)
|
||||||
print "Encoding for this connection is", conn.encoding
|
print "Encoding for this connection is", conn.encoding
|
||||||
|
|
||||||
|
|
|
@ -27,7 +27,7 @@ import psycopg2
|
||||||
if len(sys.argv) > 1:
|
if len(sys.argv) > 1:
|
||||||
DSN = sys.argv[1]
|
DSN = sys.argv[1]
|
||||||
|
|
||||||
print "Opening connection using dns:", DSN
|
print "Opening connection using dsn:", DSN
|
||||||
conn = psycopg2.connect(DSN)
|
conn = psycopg2.connect(DSN)
|
||||||
print "Encoding for this connection is", conn.encoding
|
print "Encoding for this connection is", conn.encoding
|
||||||
|
|
||||||
|
|
|
@ -27,7 +27,7 @@ import psycopg2
|
||||||
if len(sys.argv) > 1:
|
if len(sys.argv) > 1:
|
||||||
DSN = sys.argv[1]
|
DSN = sys.argv[1]
|
||||||
|
|
||||||
print "Opening connection using dns:", DSN
|
print "Opening connection using dsn:", DSN
|
||||||
conn = psycopg2.connect(DSN)
|
conn = psycopg2.connect(DSN)
|
||||||
print "Encoding for this connection is", conn.encoding
|
print "Encoding for this connection is", conn.encoding
|
||||||
|
|
||||||
|
|
|
@ -28,7 +28,7 @@ from psycopg2.extensions import adapt
|
||||||
if len(sys.argv) > 1:
|
if len(sys.argv) > 1:
|
||||||
DSN = sys.argv[1]
|
DSN = sys.argv[1]
|
||||||
|
|
||||||
print "Opening connection using dns:", DSN
|
print "Opening connection using dsn:", DSN
|
||||||
conn = psycopg2.connect(DSN)
|
conn = psycopg2.connect(DSN)
|
||||||
curs = conn.cursor()
|
curs = conn.cursor()
|
||||||
|
|
||||||
|
|
|
@ -26,7 +26,7 @@ import psycopg2.extensions
|
||||||
if len(sys.argv) > 1:
|
if len(sys.argv) > 1:
|
||||||
DSN = sys.argv[1]
|
DSN = sys.argv[1]
|
||||||
|
|
||||||
print "Opening connection using dns:", DSN
|
print "Opening connection using dsn:", DSN
|
||||||
conn = psycopg2.connect(DSN)
|
conn = psycopg2.connect(DSN)
|
||||||
print "Initial encoding for this connection is", conn.encoding
|
print "Initial encoding for this connection is", conn.encoding
|
||||||
|
|
||||||
|
|
|
@ -24,7 +24,7 @@ import psycopg2
|
||||||
if len(sys.argv) > 1:
|
if len(sys.argv) > 1:
|
||||||
DSN = sys.argv[1]
|
DSN = sys.argv[1]
|
||||||
|
|
||||||
print "Opening connection using dns:", DSN
|
print "Opening connection using dsn:", DSN
|
||||||
conn = psycopg2.connect(DSN)
|
conn = psycopg2.connect(DSN)
|
||||||
print "Encoding for this connection is", conn.encoding
|
print "Encoding for this connection is", conn.encoding
|
||||||
|
|
||||||
|
|
|
@ -23,7 +23,7 @@ import sys, psycopg2
|
||||||
if len(sys.argv) > 1:
|
if len(sys.argv) > 1:
|
||||||
DSN = sys.argv[1]
|
DSN = sys.argv[1]
|
||||||
|
|
||||||
print "Opening connection using dns:", DSN
|
print "Opening connection using dsn:", DSN
|
||||||
conn = psycopg2.connect(DSN)
|
conn = psycopg2.connect(DSN)
|
||||||
curs = conn.cursor()
|
curs = conn.cursor()
|
||||||
|
|
||||||
|
|
|
@ -24,7 +24,7 @@ import psycopg2
|
||||||
if len(sys.argv) > 1:
|
if len(sys.argv) > 1:
|
||||||
DSN = sys.argv[1]
|
DSN = sys.argv[1]
|
||||||
|
|
||||||
print "Opening connection using dns:", DSN
|
print "Opening connection using dsn:", DSN
|
||||||
conn = psycopg2.connect(DSN)
|
conn = psycopg2.connect(DSN)
|
||||||
print "Encoding for this connection is", conn.encoding
|
print "Encoding for this connection is", conn.encoding
|
||||||
|
|
||||||
|
|
|
@ -24,7 +24,7 @@ import sys, psycopg2
|
||||||
if len(sys.argv) > 1:
|
if len(sys.argv) > 1:
|
||||||
DSN = sys.argv[1]
|
DSN = sys.argv[1]
|
||||||
|
|
||||||
print "Opening connection using dns:", DSN
|
print "Opening connection using dsn:", DSN
|
||||||
|
|
||||||
conn = psycopg2.connect(DSN)
|
conn = psycopg2.connect(DSN)
|
||||||
print "Encoding for this connection is", conn.encoding
|
print "Encoding for this connection is", conn.encoding
|
||||||
|
|
|
@ -26,7 +26,7 @@ from psycopg2.extensions import ISOLATION_LEVEL_AUTOCOMMIT
|
||||||
if len(sys.argv) > 1:
|
if len(sys.argv) > 1:
|
||||||
DSN = sys.argv[1]
|
DSN = sys.argv[1]
|
||||||
|
|
||||||
print "Opening connection using dns:", DSN
|
print "Opening connection using dsn:", DSN
|
||||||
conn = psycopg2.connect(DSN)
|
conn = psycopg2.connect(DSN)
|
||||||
print "Encoding for this connection is", conn.encoding
|
print "Encoding for this connection is", conn.encoding
|
||||||
|
|
||||||
|
|
|
@ -30,7 +30,7 @@ import psycopg2
|
||||||
if len(sys.argv) > 1:
|
if len(sys.argv) > 1:
|
||||||
DSN = sys.argv[1]
|
DSN = sys.argv[1]
|
||||||
|
|
||||||
print "Opening connection using dns:", DSN
|
print "Opening connection using dsn:", DSN
|
||||||
conn = psycopg2.connect(DSN)
|
conn = psycopg2.connect(DSN)
|
||||||
print "Encoding for this connection is", conn.encoding
|
print "Encoding for this connection is", conn.encoding
|
||||||
|
|
||||||
|
|
|
@ -45,7 +45,7 @@ if len(sys.argv) > 1:
|
||||||
if len(sys.argv) > 2:
|
if len(sys.argv) > 2:
|
||||||
MODE = int(sys.argv[2])
|
MODE = int(sys.argv[2])
|
||||||
|
|
||||||
print "Opening connection using dns:", DSN
|
print "Opening connection using dsn:", DSN
|
||||||
conn = psycopg2.connect(DSN)
|
conn = psycopg2.connect(DSN)
|
||||||
curs = conn.cursor()
|
curs = conn.cursor()
|
||||||
|
|
||||||
|
|
|
@ -29,7 +29,7 @@ import psycopg2.extensions
|
||||||
if len(sys.argv) > 1:
|
if len(sys.argv) > 1:
|
||||||
DSN = sys.argv[1]
|
DSN = sys.argv[1]
|
||||||
|
|
||||||
print "Opening connection using dns:", DSN
|
print "Opening connection using dsn:", DSN
|
||||||
conn = psycopg2.connect(DSN)
|
conn = psycopg2.connect(DSN)
|
||||||
print "Encoding for this connection is", conn.encoding
|
print "Encoding for this connection is", conn.encoding
|
||||||
|
|
||||||
|
|
|
@ -28,7 +28,7 @@ from psycopg2.tz import ZERO, LOCAL, FixedOffsetTimezone
|
||||||
if len(sys.argv) > 1:
|
if len(sys.argv) > 1:
|
||||||
DSN = sys.argv[1]
|
DSN = sys.argv[1]
|
||||||
|
|
||||||
print "Opening connection using dns:", DSN
|
print "Opening connection using dsn:", DSN
|
||||||
conn = psycopg2.connect(DSN)
|
conn = psycopg2.connect(DSN)
|
||||||
curs = conn.cursor()
|
curs = conn.cursor()
|
||||||
|
|
||||||
|
|
|
@ -33,7 +33,7 @@ import psycopg2.extras
|
||||||
if len(sys.argv) > 1:
|
if len(sys.argv) > 1:
|
||||||
DSN = sys.argv[1]
|
DSN = sys.argv[1]
|
||||||
|
|
||||||
print "Opening connection using dns:", DSN
|
print "Opening connection using dsn:", DSN
|
||||||
conn = psycopg2.connect(DSN)
|
conn = psycopg2.connect(DSN)
|
||||||
print "Initial encoding for this connection is", conn.encoding
|
print "Initial encoding for this connection is", conn.encoding
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user