开发者

UnixODBC driver support in OSX?

I'm working on a Rails application which I've set up locally on my OSX Machine. However, the app, which typically runs on a Linux box, connects to a proprietary database via unixODBC. The database man开发者_运维知识库ufacturer only provides drivers for Linux and Windows. I did some searching around but couldn't figure out what the state of unixODBC is on OSX. Is there any binary compatibility with Linux drivers, or am I setting up another machine?

Thanks for your time,

-- Henry


iODBC, maintained and supported by my employer, has shipped as part of Mac OS X since Jaguar (10.2.x).

You'll be better off updating iODBC with all the latest patches (Apple tends to be a bit behind on these), than shifting to UnixODBC. You may also find some benefit in the Ruby+ODBC and Ruby-on-Rails docs we've published.

It's generally best to keep all your ODBC configuration in the default file locations for Mac OS X --

/Library/ODBC/odbc.ini
/Library/ODBC/odbcinst.ini
/Users/*/Library/ODBC/odbc.ini
/Users/*/Library/ODBC/odbcinst.ini

You can create symlinks from anywhere else you may want to have these files, e.g. --

ln -s ~/Library/ODBC/odbc.ini ~/.odbc.ini

Without knowing the target DBMS, it's impossible to point you to any DBMS-specific ODBC drivers for Mac OS X. However, my employer does offer a cross-platform Multi-Tier ODBC Bridge solution, which will let Mac OS X client applications connect through ODBC drivers on Windows or Linux.


Use Macports to install unixODBC. There are a lot of configuration files to get it going. The binaries will appear under "/opt/local/bin".

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜