Offsetting flight emissions

Posted by Matt Parrish Sun, 20 Aug 2006 18:48:00 GMT

I’m flying back to Phoenix today, as part of my telecommuting agreement. Due to the fact that I’ll be flying frequently, I feel that I should do something to balance the impact on the environment of my flights. Flying burns a lot of fuel, and flying from Columbus, OH to Phoenix, AZ is certainly no exception. So, today, I’m purchasing a Flight TerraPass to offset the carbon emissions of my flights.

Ahh, the easy life

Posted by Matt Parrish Mon, 14 Aug 2006 18:46:00 GMT

This is what my dog does while I work all day…

Error working with large YAML files

Posted by Matt Parrish Sun, 13 Aug 2006 18:34:00 GMT

As part of my Application migration project, I need to pre-populate the new database with zip code data. The Rails Recipes book (very useful) has a nice recipe on extracting fixtures from live data. So, I’ve created a zips.yml file that contains all the zip code data that I can insert into the new database. However, when I try to load the fixture using this very cool rake task from Technoweenie, the YAML library throws the following exception: SystemStackError: stack level too deep.

Rails Migrations - Dropping default constraint on column

Posted by Matt Parrish Sun, 13 Aug 2006 18:31:00 GMT

I’m working on a project for a client to convert a website from PHP to Ruby on Rails. The database is also changing from Microsoft SQL Server to MySQL, along with several schema redesigns.

One thing I wanted to do to our new db, was change a foreign key column from NOT NULL DEFAULT 0 to allow nulls and remove the default. Currently, the organizations table has a record with ID = 0 to signify a blank organization. Users that do not belong to an organization, have a foreign key to that Zero-record. Well, a better way to represent that is for the foreign key column in users to simply be NULL and ditch the Zero-record in the organizations table.

I have created a Migration class to handle the schema change. However, it looks like I have to drop to SQL as there is not Migration way of doing this. Here’s what it looks like:

    execute 'ALTER TABLE users ALTER organization_id DROP DEFAULT'

I wanted to be able to handle this in the Migration-syntax, but I don’t think that’s possible. It would be nice to do something like:

    change_column :users, :organization_id, :integer, :default => :null, :null => true

Cool Google Maps flight simulator

Posted by Matt Parrish Sun, 06 Aug 2006 18:07:00 GMT

Now this is a pretty cool idea!

Go There!

Rails redeploy issue resolved

Posted by Matt Parrish Sun, 06 Aug 2006 16:25:00 GMT

I just redeployed a rails site for a client of mine, Real Idaho, using Capistrano and it didn’t work properly. I was able to resolve the issue, and here are the details in case this ever happens to you…

Solar Wi-Fi To Bring Net to Developing Countries

Posted by Matt Parrish Fri, 04 Aug 2006 16:24:00 GMT

I think this is a very cool idea and one I am very glad to see happening. I really think efforts like this can be worldchanging, and do a lot to help people, especially children, in the developing world to have more opportunities. The project is Green WiFi and is founded by Bruce Baikie, former manager of strategic marketing and solutions for the telecommunications industry at Sun Microsystems, and Marc Pomerleau, currently a member of Sun Microsystem’s identity management marketing team. According to their site:

“GREEN-WiFi strives to apply smart, sustainable, communications technologies to help bridge the digital divide for children in the developing world. A solar-powered Wi-Fi grid network solution can be part of the answer.”

Here’s a link to the story on Slashdot.

Is your site really Web 2.0? 1

Posted by Matt Parrish Thu, 03 Aug 2006 16:07:00 GMT

Now you can run your website through a handy-dandy Web 2.0 validator, to see if it really is Web 2.0. This site was put together by 30 Second Rule, a website design and development company in Phoenix that is active in the Ruby community. My blog’s score should be upped by writing this article! :)

Go to the Web 2.0 Validator