MustModify Blog: Recent Posts

Organizing Search Results with Multiple Criteria using SQL

May 23, 2009
I love ruby; but for hard-core data manipulation, there's no place like the database. (I'm a poet.) Here's an clever way to sort results based on multiple criteria. Credit for this trick goes to "Erika Valentine":http://www.linkedin.com/pub/erika-valentine/13/49b/933 , who knows roughly everything about T-SQL.  Story:  As a consumer, I...


Elegant Code

May 14, 2009
Borrowing from Einstein... "Code should be as elegant as is readable, but not more elegant."


A video every Ruby developer should watch. ( and all other devs, but they would be sad.)

May 11, 2009
Every developer should watch "What killed SmallTalk could it kill Ruby, too.":http://railsconf.blip.tv/file/2089545/ from RailsConf. This is a whirlwind tour through the history of software development from Small Talk to C++ to Ruby. It is both ammusing and informative. He also talks about two of my favorite subjects, "Test Driven...


Good Times with Ruby

May 05, 2009
You know you work with a good language when one of your biggest challenges of the day is to find the right word to model a relationship.


received unexpected message :split [ an error in an rspec controller test ]

April 23, 2009
original code: --- ruby it 'should add a flight given the correct data' do details = Factory.build(:flight).attributes @mock_flight.should_receive(:save).and_return(true)   Flight.should_receive(:new).with(details).and_return(@mock_flight) post 'create', :flight => details response.should redirect_to( @mock_flight...


[Rails error] Unpacked Gem has no specification file.

April 20, 2009
Recently I started working on a new project. Every time I did anything from the command line, I got this irritating error message when rails loaded it's environment:  config.gem: Unpacked gem in vendor/gems has no specification file. Run 'rake gems:refresh_specs' to fix this. I run rake gems:refresh_specs. I get: config.gem: Unpacked...


"With all the Rights and Responsibilities ..." (a quotation)

April 16, 2009
"I've given you admin privileges ... this way you can see everything. Please do not make any changes to the data." - Shawn


Refresh a page using Javascript

March 24, 2009
Courtesy of the great Panda, here's how to refresh a page using javascript. It's one of those things that makes sense once you see it, but that I doubt I would have guessed had I needed it. ---js window.location = window.location