[unixODBC-support] GRASS and ODBC help wanted

"Georg (öffentlich)" stuff at de-schorsch.de
Thu Nov 29 17:39:04 GMT 2007

Hi all,

I need some help.

OS: Debian Etch

I try to connect GRASS [1] via odbc to my local PostgreSQL database. The
case is for a training lession about this gis. I connect to Postgres
because i have no other db.

The direct contact to the PostgresQL runs without problems.

I have this


Description         = Test to Postgres
Driver              = PostgreSQL
Trace               = Yes
TraceFile           = sql.log
Database            = grass_nc
Servername          = localhost
UserName            = verysecret
Password            = verysecret
Port                = 5432
Protocol            = 8.1
ReadOnly            = No
RowVersioning       = No
ShowSystemTables    = No
ShowOidColumn       = No
FakeOidIndex        = No
ConnSettings        =
odbc.ini (END)


Description     = PostgreSQL driver for Linux & Win32
Driver          = /usr/lib/odbc/libodbcpsqlS.so
Setup           = /usr/lib/odbc/libodbcpsqlS.so
Threading       = 2
UsageCount      = 1

both data located in my local home


Postgres runs

ok now comes some grass stuff

set connection

GRASS 6.2.1 (solothurn):~/solothurn > db.login driver=odbc
database=grass_via_odbc user=secret password=secret
WARNING: The password was stored in file.

check connection

GRASS 6.2.1 (solothurn):~/solothurn > db.connect -p

and then when i try this

GRASS 6.2.1 (solothurn):~/solothurn > g.copy
COPY [avdpool_liegen at PERMANENT] to current mapset as [liegen_odbc1]
DBMI-ODBC driver error: SQLConnect():
[unixODBC][Driver Manager]Driver's SQLAllocHandle on SQL_HANDLE_HENV
failed (0)
WARNING: Cannot open database 'grass_via_odbc'
no database is open
WARNING: Cannot copy table
WARNING: Cannot copy avdpool_liegen at PERMANENT to current mapset as

Any idea where the problem is?
Any hint?

Thanks in advance

greeting Georg

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 186 bytes
Desc: OpenPGP digital signature
URL: <http://mailman.unixodbc.org/pipermail/unixodbc-support/attachments/20071129/9ff623c1/attachment.bin>

More information about the unixODBC-support mailing list