Topic: updated_at troubles.

I'm having some problems with my create methods in controllers, as each new record I create has the updated_at column set with the same value as created_at, the column is :default => nil so that shouldnt be the problem.

Is the updated_at column supposed to be set for new records also, or am I right in thinking it should remain as nil until update_attributes is called on the record? I'm just wondering if its an error somewhere in my app or if this is working correctly, as I'm wondering how to best display the updated_at time for only updated records in a view.

Re: updated_at troubles.

You have no error in your app. Everything works like it should.
The updated_at column is set to the same date/time as created_at for a new record.

If you want to have all updated records, just compare the two dates. When they are different, the record was updated.

My homepage: http://www.komendera.com/
Working at: http://www.abloom.at/
My blog: soaked and soaped http://soakedandsoaped.com/

Re: updated_at troubles.

ah, so its working as it should, guess I was just wishing it were a nil for easier checking wink
I suppose theres not an existing helper like is_updated?, couldnt find one in the api page at least, guess I'll write a quick one of my own.

as always, thanks for the great help.