At the Forge - Working with ActiveRecord
Although constraints in our database ensure that the data will always be valid, we generally want to perform such validation at the application level. Unfortunately, doing so is tricky or time consuming in many languages. ActiveRecord, the object-relational mapper at the heart of Ruby on Rails, makes it relatively easy to ensure that your users never have to see a database error. It comes with a number of validators, as well as an infrastructure for creating custom ones. Moreover, it comes with a number of routines that let us describe the relationships among different tables. With some small modifications to the controllers, views and models, we are able to create a custom application with valid data quickly.
Resources for this article: /article/8580.
One Click, Universal Protection: Implementing Centralized Security Policies on Linux Systems
Join editor Bill Childers and Bit9's Paul Riegle on April 27 at 12pm Central to learn how to keep your Linux systems secure.
Free to Linux Journal readers.Register Now!
- [<Megashare>] Watch Mrs Brown's Boys Movie Online Full Movie HD 2014
- Considering Legacy UNIX/Linux Issues
- Cluetrain at Fifteen
- Memory Ordering in Modern Microprocessors, Part I
- New Products
- RSS Feeds
- Python Scripts as a Replacement for Bash Utility Scripts
- Getting Good Vibrations with Linux
- Readers' Choice Awards 2013
- Tech Tip: Really Simple HTTP Server with Python