I have record in my db where there is a time element which is a number stored as a string. I'd like to run a where query where I check if the number is greater than x e.g.
Recording.where("recording_duration_ms.to_i > 60000")
Sure it must be simple to do...
recording_duration_msstored as a string? Wouldn't it make more sense to fix your schema rather than kludging around it?Client.where("recording_duration_to_ms > ?", 60000)