SQL Naming conventions

I’m not a DBA, and I don’t do a lot of SQL.  What I do use is Hibernate!  Some conventions have been kept around for years, when they aren’t really needed.

I’m not a big fan of my column names repeating my tables names:

For instance an Address table with column names like address_id, address_street1, state_id.

I understand that when your doing SQL joins this allows you to avoid naming collisions.  But in my world, I’m never using the table names or column names except for in my annotations.

Following this convention actually requires me to add @Column(name = “address_street1″) to my object, instead of simply @Column

With my preferred approach, my columns match up nicely with my domain objects/data models.  I don’t want to have to add the “name” part to my @Column annotation.

Can we all agree that from now on, we write our model objects and database tables so that we don’t need the (name = “address_street1″) part?  Please?

Ubuntu + HTC EVO + EasyTether = Sweetness

It was just that easy.  I purchased the EasyTether application from the Android store because it was the only one that suggested that it would work with my Ubuntu OS running on my Asus Eee.

I downloaded the Ubuntu software component from the website.

Connected my netbook to the Evo via the USB connection and mounted the EVO as a drive.  I then installed the .deb that I just downloaded from the “downloads” directory on the Evo.  I just double clicked and then was asked for admin login to finish the install.  I’m sure a command line ‘sudo deb something’ would have worked just as well.

The application asked me to change a USB setting and then took me right to the setting.  I made the change.

Then I clicked finish.

On the netbook, I had to run two commands to get it going, but the application told me exactly what to run.

Ding!  I’m connected.

It works!  No problems what so ever.  I will install the same thing on my wife’s Evo and netbook.  I will just give her a couple of icons in her menu to use instead of having her use the terminal like the software suggested.

Ubuntu 10.10 Rails Environement

Here is what I did that worked:

  • Downloaded sources from here.
  • sudo aptitude install build-essential libssl-dev libreadline5 libreadline5-dev zlib1g zlib1g-dev sqlite3 libsqlite3-dev
  • ‘unzip’ sources into a directory and ‘cd’ into that directory
  • ./configure
  • make
  • make test (to make sure everything is working)
  • sudo make install

Because Ruby 1.9.2 has Gem 1.3.7 included, I can now install rails

  • sudo gem install rails
  • rails new path/to/source
  • cd path/to/source
  • bundle install (to create sqlite3 gem)
  • rails server

Bling!

http://localhost:3000