Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Deploying ODBC for Postgres

4 views
Skip to first unread message

Benjamin Scherrey

unread,
Nov 17, 2002, 3:35:16 PM11/17/02
to
I'm now deploying my Postgresql backend for Access solution to the customer. The customer has
twenty-something odd workstations that may run clients but they are dispersed around the campus
and would prefer not to have to physically send a support person to each workstation. The driver
installation program is simple enough for me to just put it up on the network for users to click/run on
their workstations. My question is how to get the system DSN installed on each workstation for my
backend Postgres database connection? Can I write some script or something to make this happen
automagically?

thanx & later,

Ben Scherrey

---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

Dave Page

unread,
Nov 17, 2002, 3:48:37 PM11/17/02
to
Hi Ben,

You can do this through a login script and/or regedit. Copy the
psqlodbc.dll to the windows system directory on each PC, then insert the
appropriate registry settings. You will need to install those for the
driver and the DSN - some sample registry entries are shown below. One
thing to watch out for, non-admins cannot usually write these entries on
w2k/xp due to the default permissions on HKEY_LOCAL_MACHINE.

Another option is to use msiexec.exe from the command line/login script
to automatically run the psqlodbc installer, in silent mode. Check the
Microsoft documentation for the msiexec command line options.

Regards, Dave.

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\MyDSN]
"Driver"=3D"C:\\WINDOWS\\System32\\psqlodbc.dll"
"Description"=3D""
"Database"=3D"template1"
"Servername"=3D"postgresql"
"Port"=3D"5432"
"Username"=3D""
"Password"=3D""
"ReadOnly"=3D"0"
"ShowOidColumn"=3D"0"
"FakeOidIndex"=3D"0"
"RowVersioning"=3D"0"
"ShowSystemTables"=3D"0"
"Protocol"=3D"6.4"
"ConnSettings"=3D""
"DisallowPremature"=3D"0"
"UpdatableCursors"=3D"0"
"LFConversion"=3D"1"
"TrueIsMinus1"=3D"0"
"Fetch"=3D"100"
"CommLog"=3D"1"
"Debug"=3D"0"
"Optimizer"=3D"1"
"Ksqo"=3D"1"
"UniqueIndex"=3D"1"
"UseDeclareFetch"=3D"0"
"UnknownSizes"=3D"0"
"TextAsLongVarchar"=3D"1"
"UnknownsAsLongVarchar"=3D"0"
"BoolsAsChar"=3D"1"
"Parse"=3D"0"
"CancelAsFreeStmt"=3D"0"
"MaxVarcharSize"=3D"254"
"MaxLongVarcharSize"=3D"8190"
"ExtraSysTablePrefixes"=3D"dd_;"
"BI"=3D"0"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\ODBC Data Sources]
"MyDSN"=3D"PostgreSQL"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\ODBC Drivers]
"PostgreSQL"=3D"Installed"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\PostgreSQL]
"UsageCount"=3Ddword:00000001
"Driver"=3D"C:\\WINDOWS\\System32\\psqlodbc.dll"
"Setup"=3D"C:\\WINDOWS\\System32\\psqlodbc.dll"
"SQLLevel"=3D"1"
"DriverODBCVer"=3D"02.50"
"FileUsage"=3D"0"
"APILevel"=3D"1"
"ConnectFunctions"=3D"YYN"

> -----Original Message-----
> From: Benjamin Scherrey [mailto:sche...@proteus-tech.com]=20
> Sent: 17 November 2002 20:34
> To: pgsql...@postgresql.org
> Subject: [ODBC] Deploying ODBC for Postgres
>=20
>=20
> I'm now deploying my Postgresql backend for Access solution=20
> to the customer. The customer has=20
> twenty-something odd workstations that may run clients but=20
> they are dispersed around the campus=20
> and would prefer not to have to physically send a support=20
> person to each workstation. The driver=20
> installation program is simple enough for me to just put it=20
> up on the network for users to click/run on=20
> their workstations. My question is how to get the system DSN=20
> installed on each workstation for my=20
> backend Postgres database connection? Can I write some script=20
> or something to make this happen=20
> automagically?
>=20
> thanx & later,
>=20
> Ben Scherrey
>=20
>=20
>=20
> ---------------------------(end of=20


> broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster

>=20

---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://archives.postgresql.org

0 new messages