Postgres via odbc?

Carlos carlos@REDACTED
Mon May 31 12:33:51 CEST 2004


El 17 de May de 2004, Ingela Anderton wrote...

> 
> There is a much better solution that does not require you to change
> the c-code of the Erlang odbc-application, and that is too
> disable scrollable cursors when opening your connection.
> 
> odbc:connect(ConnectionString, [{scrollable_cursors, off}])
> 
> When doing that you will get the exact same effect as your workaround
> below but without any hassles ;)
> 
> This is mentioned in the ODBC users guide if anybody would bother to
> read it!

Indeed, it is a better solution than editing the C code :).

These days we have been testing the last Erlang release (R9C-1) and,
unfortunately, the Erlang ODBC support doesn't compile yet in an i686
linux machine. Nevertheless, the solution is pretty simple and we hope it
to be useful for other users:

	* Be sure that the LC_ALL enviroment variable is set to C (as
	  during the architecture detection, the output of some
	  shell comands are used and english output is expected)

	* Set the undocumented ERLANG_COMMERCIAL_BUILD enviroment variable
	  with any value like "ACME Erlang Build" :)

	* Run the configure command

		./configure ... --enable-odbc

	* In the <otp-src-erlang-home>/lib/Makefile and the
	  <otp-src-erlang-home>/lib/odbc/c_src/i686-pc-linux-gnu/Makefile
	  files look for the conditional statements involving "solaris" and
	  comment them out (note that we are working with an
	  i686-pc-linux-gnu box)

	* Finally, compile and install.

Enjoy it


-- Carlos.



More information about the erlang-questions mailing list