<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>just in ram &#187; Ruby on Rails</title>
	<atom:link href="http://justinramel.com/category/ruby/ruby-on-rails/feed/" rel="self" type="application/rss+xml" />
	<link>http://justinramel.com</link>
	<description>A list of stuff I should remember but never do</description>
	<lastBuildDate>Sat, 24 Jul 2010 10:14:06 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Connecting Ruby on Rails to Microsoft SQL Server</title>
		<link>http://justinramel.com/2006/04/07/connecting-ruby-on-rails-to-microsoft-sql-server/</link>
		<comments>http://justinramel.com/2006/04/07/connecting-ruby-on-rails-to-microsoft-sql-server/#comments</comments>
		<pubDate>Fri, 07 Apr 2006 20:39:21 +0000</pubDate>
		<dc:creator>Justin Ramel</dc:creator>
				<category><![CDATA[Ruby on Rails]]></category>

		<guid isPermaLink="false">https://justinram.wordpress.com/2006/04/07/connecting-ruby-on-rails-to-microsoft-sql-server/</guid>
		<description><![CDATA[NOTE: These instructions are now seriously out of date. You may want to check out my always up to date *cheap* ebook instead. Connecting Ruby on Rails to Microsoft SQL Server eBook

It appears rails does not connect to MS SQL Server right out of the box.  You need to do the following to get [...]]]></description>
			<content:encoded><![CDATA[<p><strong>NOTE: These instructions are now seriously out of date. You may want to check out my always up to date *cheap* ebook instead. <a href="/rails2ms-sql/">Connecting Ruby on Rails to Microsoft SQL Server eBook</a></strong></p>
<p><center><a href="/rails2ms-sql/"><img src="/rails2ms-sql/images/banner.png" /></a></center></p>
<p>It appears rails does not connect to MS SQL Server right out of the box.  You need to do the following to get the connection to work:</p>
<p>Get the latest source distribution of <a href="http://rubyforge.org/projects/ruby-dbi/" target="_blank">Ruby-DBI</a> and copy the file:</p>
<pre>bdi-0.1.0/lib/dbd/ADO.rb</pre>
<p>to:</p>
<pre>c:/ruby/lib/ruby/site_ruby/1.8/DBD/ADO/ADO.rb</pre>
<p><strong>NOTE: The ADO directory does not exist on a standard install, you will need to create it.</strong></p>
<p>Then simply set up your railsapp/config/database.yml</p>
<p>Here’s an example for reference:</p>
<pre>
development:
  adapter: sqlserver
  database: database_name
  host: server_name
  username: user_name
  password: your_pw_here
</pre>
]]></content:encoded>
			<wfw:commentRss>http://justinramel.com/2006/04/07/connecting-ruby-on-rails-to-microsoft-sql-server/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		</item>
		<item>
		<title>Migrations &#039;Zombie State&#039; and MS SQL</title>
		<link>http://justinramel.com/2006/04/04/migrations-zombie-state-and-ms-sql/</link>
		<comments>http://justinramel.com/2006/04/04/migrations-zombie-state-and-ms-sql/#comments</comments>
		<pubDate>Tue, 04 Apr 2006 13:28:44 +0000</pubDate>
		<dc:creator>Justin Ramel</dc:creator>
				<category><![CDATA[Ruby on Rails]]></category>

		<guid isPermaLink="false">http://justinram.wordpress.com/2006/04/04/migrations-zombie-state-and-ms-sql/</guid>
		<description><![CDATA[Getting &#8216;Zombie State&#8217; errors with migrations and MS SQL Server? Add the following to your config/enviroment.rb:

ActiveRecord::Base.connection.instance_variable_get("@connection")["AutoCommit"] = false

]]></description>
			<content:encoded><![CDATA[<p>Getting &#8216;Zombie State&#8217; errors with migrations and MS SQL Server? Add the following to your config/enviroment.rb:</p>
<pre>
ActiveRecord::Base.connection.instance_variable_get("@connection")["AutoCommit"] = false
</pre>
]]></content:encoded>
			<wfw:commentRss>http://justinramel.com/2006/04/04/migrations-zombie-state-and-ms-sql/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Pluralize table names &#8211; no thanks!</title>
		<link>http://justinramel.com/2006/04/04/pluralize-table-names-no-thanks/</link>
		<comments>http://justinramel.com/2006/04/04/pluralize-table-names-no-thanks/#comments</comments>
		<pubDate>Tue, 04 Apr 2006 13:05:19 +0000</pubDate>
		<dc:creator>Justin Ramel</dc:creator>
				<category><![CDATA[Ruby on Rails]]></category>

		<guid isPermaLink="false">http://justinram.wordpress.com/2006/04/04/pluralize-table-names-no-thanks/</guid>
		<description><![CDATA[Sorry I just can&#8217;t live with plural table names, I just can&#8217;t get my head around it! Luckily it is easily turned off. In RadRails there is a simple tick box when creating the project which simply adds the following line to the end of your applications config/environment.rb file:

# Include your application configuration below
ActiveRecord::Base.pluralize_table_names = [...]]]></description>
			<content:encoded><![CDATA[<p>Sorry I just can&#8217;t live with plural table names, I just can&#8217;t get my head around it! Luckily it is easily turned off. In RadRails there is a simple tick box when creating the project which simply adds the following line to the end of your applications config/environment.rb file:</p>
<pre>
# Include your application configuration below
ActiveRecord::Base.pluralize_table_names = false
</pre>
<p>I may live to regret not embracing plural table names but I doubt it!</p>
]]></content:encoded>
			<wfw:commentRss>http://justinramel.com/2006/04/04/pluralize-table-names-no-thanks/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>Setting up Ruby on Rails</title>
		<link>http://justinramel.com/2006/04/04/setting-up-ruby-on-rails/</link>
		<comments>http://justinramel.com/2006/04/04/setting-up-ruby-on-rails/#comments</comments>
		<pubDate>Tue, 04 Apr 2006 10:26:22 +0000</pubDate>
		<dc:creator>Justin Ramel</dc:creator>
				<category><![CDATA[Ruby on Rails]]></category>

		<guid isPermaLink="false">http://justinram.wordpress.com/2006/04/04/setting-up-ruby-on-rails/</guid>
		<description><![CDATA[I&#8217;m going to give Ruby on Rails (RoR) a try on my Windows XP machine.  Here&#8217;s how I&#8217;ve set it up&#8230;

Install Ruby
Using the Ruby One Click Installer Ruby One Click Installer (v184-16 release candidate 1)
Setup proxy
set HTTP_PROXY=http://wwwcache:8080

GEM install Ruby on Rails
gem install rails --include-dependencies

Install RadRails
I also downloaded and installed the latest RadRails (v0.6.1) 
Database
I&#8217;m [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m going to give Ruby on Rails (RoR) a try on my Windows XP machine.  Here&#8217;s how I&#8217;ve set it up&#8230;</p>
<ol>
<li>Install Ruby<br />
Using the <a href="http://rubyforge.org/projects/rubyinstaller/" title="Ruby One Click Installer" target="_blank">Ruby One Click Installer Ruby One Click Installer</a> (v184-16 release candidate 1)</li>
<li>Setup proxy
<pre>set HTTP_PROXY=http://wwwcache:8080</pre>
</li>
<li>GEM install Ruby on Rails
<pre>gem install rails --include-dependencies</pre>
</li>
<li>Install RadRails<br />
I also downloaded and installed the latest <a href="http://www.radrails.org/" title="RadRails" target="_blank">RadRails</a> (v0.6.1) </li>
<li>Database<br />
I&#8217;m going to try rails with our dev MS-SQL server so no database to install. No doubt lots of configuring to do though!
</ol>
<h4>NOTE:</h4>
<p>There appears to be a problem with the WEBrick web server in this setup.  I couldn&#8217;t find the answer on google but I did find a work around. If you run the WEBrick server using the standard ruby script\server you will get the following error:</p>
<pre>
ruby script\server
=&gt; Booting WEBrick...
=&gt; Rails application started on http://0.0.0.0:3000
=&gt; Ctrl-C to shutdown server; call with --help for options
[2006-04-04 13:20:35] INFO  WEBrick 1.3.1
[2006-04-04 13:20:35] INFO  ruby 1.8.4 (2005-12-24) [i386-mswin32]
[2006-04-04 13:20:35] WARN  TCPServer Error: Bad file descriptor - bind(2)
c:/ruby/lib/ruby/1.8/webrick/utils.rb:73:in `initialize': Bad file descriptor - bind(2) (Errno::EBADF)
        from c:/ruby/lib/ruby/1.8/webrick/utils.rb:73:in `create_listeners'
        from c:/ruby/lib/ruby/1.8/webrick/utils.rb:70:in `create_listeners'
        from c:/ruby/lib/ruby/1.8/webrick/server.rb:75:in `listen'
        from c:/ruby/lib/ruby/1.8/webrick/server.rb:63:in `initialize'
        from c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:24:in `initialize'
        from c:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.0/lib/webrick_server.rb:59:in `dispatch'
        from c:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.0/lib/commands/servers/webrick.rb:59
        from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:21:in `require'
        from c:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.3.0/lib/active_support/dependencies.rb:136:in `require'
        from c:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.0/lib/commands/server.rb:30
        from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:21:in `require'
        from c:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.3.0/lib/active_support/dependencies.rb:136:in `require'
        from script/server:3
</pre>
<p>There appears to be some problem binding to the port 3000, netstat shows nothing running on port 3000 so I&#8217;ve no idea what is causing it. Any hoose a work around is simply to run on another port:</p>
<pre>
ruby script\server --port=8000
</pre>
<p>If I do find out what is causing the problem I&#8217;ll update this post.</p>
]]></content:encoded>
			<wfw:commentRss>http://justinramel.com/2006/04/04/setting-up-ruby-on-rails/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
	</channel>
</rss>
