04 Jun '12, 10am

Table#index - This method does not work. #rails

When using the index method within a create_table statement, it does not have any side effect - at least not in MySQL. create_table :comment do | t | t . belongs_to :post t . timestamps # not working inside create_table ! t . index :post_id end It is working properly in change_table though change_table :comment do | t | t . belongs_to :user # this works inside change_table t . index :user_id end Unfortunately this flaw is not reported in any way. The index is just not created. I have only tested this with the mysql2 driver in Rails 2.3.x. I’m not sure, if this happens in other versions/adapters as well.

Full article: http://apidock.com/rails/ActiveRecord/ConnectionAdapters/...

Tweets

@wayoutmind @nlsmith I usually refer to but tho...

guides.rubyonrails.org 05 Jun '12, 1am

Ruby on Rails is not “someone else’s framework.” Over the years, hundreds of people have contributed to Ruby on Rails rang...

SpK's View Methods - Part 1 - The 'mobile metho...

blackhatworld.com 03 Jun '12, 6pm

SpK's View Methods - Part 1 - The 'mobile method' (and disguising as Facebook/Twitter) “Give a man a fish and you feed him...

Ruby 2.0 Implementation Work Begins: What is Ru...

rubyinside.com 03 Jun '12, 6pm

Yesterday, Matz made a commit to the MRI Ruby repository bumping the trunk version from 1.9.4 to 2.0.0 , marking the start...

Making Redis-store views cache work with simple...

rubyflow.com 03 Jun '12, 9am

Making Redis-store views cache work with simple Regexps Posted by mencio on June 03, 2012 — 0 comments I've found a way to...

“Ruby on Railsで複合キーを扱う(1) - Rails 雑感 - Ruby on ...

oiax.jp 03 Jun '12, 9pm

Ruby on Railsでは、データベーステーブルの主キーとしてidというカラムを使うのがデフォルトです。 誤解される方も多いのですが、もちろん主キーの名前は変更できます。たとえば、User モデルに対応するusers テーブルの主キーがui...

How Does A Pod Espresso Machine Work? via @Shotofcoffee

How Does A Pod Espresso Machine Work? via @Shot...

dailyshotofcoffee.com 05 Jun '12, 3pm

How Do Pod Espresso Machines Work? by A Guest Writer | 0 Comments Tweet This is a guest post by Keith Douglas. Learn more ...

Simple Test Metrics in Your Rails App, and What...

robots.thoughtbot.com 05 Jun '12, 2am

logged_in_user_context do context "with at least one purchase" do setup do @purchases = paginate([Factory(:purchase)]) @st...

May Mozscape Index Update:164 Billion URLs

seomoz.org 31 May '12, 12am

Next index, we're going back down to between 70-90 billion URLs, and focusing on getting back to much fresher updates (we'...

Ruby on Rails Guides: Configuring Rails Applica...

edgeguides.rubyonrails.org 02 Jun '12, 10pm

configures Rails itself to serve static assets. Defaults to true, but in the production environment is turned off as the s...

Screencast: Hover Content in Rails and Prototype (Part 1) - Rails Ill.:

Screencast: Hover Content in Rails and Prototyp...

railsillustrated.com 27 May '12, 9pm

Screencast: Hover Content in Rails and Prototype from Erik Andrejko on Vimeo . It is often a good idea to show content whe...

What’s New in Edge Rails #23: Week of May 28 -J...

afreshcup.com 04 Jun '12, 4pm

It was a fairly quiet week on the Rails front. Well, if you don't count multiple non-edge dot releases for security fixes....

Good news everyone! Rails 3.2.5 has been released.

weblog.rubyonrails.org 01 Jun '12, 3am

Good news everyone! Rails version 3.2.5 has been released. This version of Rails is a less broken version of 3.2.4! What h...

Good news everyone! Rails 3.2.4, 3.1.5, and 3.0...

weblog.rubyonrails.org 31 May '12, 6pm

Good news everyone! Rails version 3.1.5 has been released. This release of Rails contains two important security fixes: CV...

Good news everyone! Rails 3.2.4, 3.1.5, and 3.0...

weblog.rubyonrails.org 31 May '12, 6pm

Good news everyone! Rails version 3.2.4 has been released. This release of Rails contains two important security fixes: CV...

Good news everyone! Rails 3.2.4, 3.1.5, and 3.0...

weblog.rubyonrails.org 31 May '12, 6pm

Good news everyone! Rails version 3.0.13 has been released. This release of Rails contains two important security fixes: C...