Skip to content

heedspin/m2mbrain

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Developer ODBC

http://honoluluhacker.com/2011/01/13/using-tinytds-to-connect-to-sql-server-with-ruby-on-rails-3-for-mac-osx/

brew install freetds brew install ruby-odbc Installed /usr/local/Cellar/ruby-odbc/0.99991/lib/odbc.bundle

If brew install freetds does not work, you can install the old version:

  • copy tarball from Dropbox/opt
  • cd freetds-0.82
  • ./configure --prefix=/usr/local/Cellar/freetds/0.82 --with-tdsver=8.0 --enable-msdblib
  • make ; make install

You will need to add this to your RUBYLIB by adding the following line to .profile or .bashrc or equivalent:

export RUBYLIB="/usr/local/lib:$RUBYLIB"

You will need to edit freetds.conf

  • /usr/local/Cellar/freetds/0.82/etc
  • Check config/odbc

Edit odbcinst.ini and odbc.ini files

  • /usr/local/Cellar/unixodbc/2.3.0/etc
  • Check config/odbc

Enabling odbc:
sudo odbcinst -i -d -f /usr/local/Cellar/unixodbc/2.3.0/etc/odbcinst.ini

Test your connection

  • isql -v m2m_dsn sa password

Production/Staging ODBC

I actually don't know if this is how we did it: sudo apt-get update sudo apt-get install unixodbc unixodbc-dev tdsodbc sqsh sudo chmod 1644 /etc/odbc* /etc/freetds/freetds.conf

Modify /etc/environment and /etc/profile per the config/odbc/ubuntu hints.

Enabling odbc:
sudo odbcinst -i -d -f /etc/odbcinst.ini

Creating db/m2m_schema.rb

In database.yml, point your development db to an m2m database.

rake db:schema:dump SCHEMA=db/m2m_schema.rb

Revert database.yml.

About

Fixing Made2Manage

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published