Hello My installation of FreeTDS is not in the common directory How you i specify it to PYMSSQL
You can use the environment variables. http://www.freetds.org/userguide/envvar.htm
Andrzej,
The environment variable works for a bash execution not a python....
import _mssql conn = _mssql.connect('MSSQL','x', 'xx') cur = conn.cursor()
cur.execute('SELECT * FROM xxxxx') row = cur.fetchone() while row: print "ID=%d, Name=%s" % (row[0], row[1]) row = cur.fetchone()
conn.close()
where should i put them....
> where should i put them.... put an 'export' (sh/bash) or 'setenv' (csh) statement just before calling Python...
Log in to post a comment.
Hello
My installation of FreeTDS is not in the common directory
How you i specify it to PYMSSQL
You can use the environment variables.
http://www.freetds.org/userguide/envvar.htm
Andrzej,
The environment variable works for a bash execution not a python....
import _mssql
conn = _mssql.connect('MSSQL','x', 'xx')
cur = conn.cursor()
cur.execute('SELECT * FROM xxxxx')
row = cur.fetchone()
while row:
print "ID=%d, Name=%s" % (row[0], row[1])
row = cur.fetchone()
conn.close()
where should i put them....
> where should i put them....
put an 'export' (sh/bash) or 'setenv' (csh) statement just before calling Python...