Re: Ruby | Ruby on Rails | database MS SQL Server 2005



On Sep 26, 9:57 am, Mark Gallop <mark.gal...@xxxxxxxxx> wrote:
Hi Joe,

Erstwhile Joe wrote:
How can I configure Ruby and Ruby on Rails for use with MS SQL Server
2005?

I haven't used ADO but have been successfully using ODBC to connect to a
mssql server. This is how I created the connection:

ActiveRecord::Base.establish_connection( :adapter => 'sqlserver',
:mode => 'odbc',
:dsn => 'MyDSName',
:username => 'bob',
:password => 'bob')

I added bob as a local user (maybe domain users also work) and created
the ODBC connection called MyDSName.

Cheers,
Mark

hi
Can you kindly helpo me more on this.

I am using sql2005 express on my machine.

My server name is : RubyGujarat
username:- sa
password:- mytest

can you help me , how should i mention this in the code given by you
above.

Thanks

IronRuby

.



Relevant Pages

  • Re: Ruby | Ruby on Rails | database MS SQL Server 2005
    ... I haven't used ADO but have been successfully using ODBC to connect to a mssql server. ... I added bob as a local user and created the ODBC connection called MyDSName. ...
    (comp.lang.ruby)
  • Re: Reading mm datasource
    ... When in Word on my machine, I click on open datasource, pick Connect ... > do not seem to have a specific driver name for the connection string. ... But before you go much further, I hadn't realised you were taking that particular approach to making the connection, and AFAIK the consequence is likely to be that you will be opening your data source, using the "OLE DB Provider for ODBC data sources" which is an approach I know little about but will ...
    (microsoft.public.word.mailmerge.fields)
  • Re: VFP Updates?
    ... Try talking ODBC or OleDb and they say HU. ... make up my apps so that what ever they want to run has to be from a command ... kind of connection and assign it the right to do exactly what you want. ...
    (microsoft.public.fox.programmer.exchange)
  • Re: MS Access looks for .mdb rather than Progress schema
    ... # Same query previously worked in Progress 8.x using SQL89. ... This entry allows you to keep your existing code written with the ODBC ... BTW, if you put all of the connect information into the connect string, ... I also tried putting the whole thing in the connection string: ...
    (microsoft.public.access.modulesdaovba)
  • Re: Strange Problems with ODBC connection to SQL Server
    ... When accessing Jet data, use DAO. ... This way you are not exposing connection information in clear ... >accesses an SQL Server 2000 repository via ODBC data source. ...
    (microsoft.public.data.odbc)