Solutions!

by gregg on Sep 04, 2008

Here are the Solutions.

AddThis Social Bookmark Button Sections: lonestar | Meta: 0 comments | permalink

We highly recommend you download these challenges ahead of time. Don't try to do them yet though, we'll be working through them during the tutorial.

http://www.railsenvy.com/assets/2008/7/14/code_challenges.zip

In order to run them you'll need Ruby installed (duh), SQLite 3 (http://www.sqlite.org/download.html), and the SQLite Ruby gem (sudo gem install sqlite).

For SQLite on windows (if you don't have it):

  1. Download sqlite3 and the sqlitedll from http://www.sqlite.org/download.html
  2. Unzip both to your path. C:\ruby\bin works too.
  3. gem install sqlite3-ruby --source http://code.whytheluckystiff.net

For SQLite on Mac version less than 10.5.0 (if you don't have it):

  1. Go to http://www.sqlite.org/download.html and download a precompiled binary.
  2. gem install sqlite

To be absolutely sure the code we've supplied can run, go into the 1-named_scope directory and run "ruby user_spec.rb". If the tests pass, you're good to go!

Sharding
During the second part of the presentation we went over the Data Fabric gem for doing sharding in ActiveRecord.

AddThis Social Bookmark Button Sections: lonestar Speaking | Meta: 0 comments | permalink