Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Re: odbc in linux and segmentation fault


From   kturner@stata.com (Kevin Turner)
To   statalist@hsphsun2.harvard.edu
Subject   st: Re: odbc in linux and segmentation fault
Date   Thu, 20 Nov 2003 11:13:48 -0600

Francesco Cota (yupa@lycos.it) writes:

>I'm running stata 8 under linux (debian, but I have the same problem 
>with fedora core 1) and the odbc function give a segmentation fault 
>trying to query a postgresql database..
>postgresql version 7.3.4-9
>odbc-postgresql version 7.3.4-9
>iodbc version 3.51.1-3
>
>Have anybody had similar problem?
>Any suggestion???

I have been in contact with Francesco privately and the preliminary diagnosis
is that the odbc-postgres driver he is using is probably incorrect. Francesco
described a situation where every -odbc- command (describe, query, load,
insert, etc.) resulted in a crash, which leads me to believe the fault lies 
with the version of the Postgres ODBC driver he is using. With the only
variation being the Postgres ODBC driver, I successfully tested the following
configuration:

	Fedora core 1
	Postgres 7.3  		
	psqlODBC 7.3.200   <--- see http://www.postgres.org to obtain  
	iODBC 3.51

Apart from specifying a different database name, server, and user/password, my
Postgres driver configuration (~/.odbc.ini) was also fairly typical (x's were 
substituted to protect information):

	[xxxx]
	Debug = 1
	CommLog = 1
	ReadOnly = no
	Driver = /usr/local/lib/psqlodbc.so
	Servername  = xx.xxx.xxx.xx
	FetchBufferSize = 99
	Username = xxxxxxx 
	Password = xxxxxxx
	Port = 5432
	Database = xxxx 

Pending a test on Francesco's machine, I believe the solution is to use the
latest Posgres ODBC driver (psqlODBC 7.3.200). 

--Kevin 
kturner@stata.com
*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index