 <p>To get a dynamic select from the appropriate table, you can use a dynamic SQL finder.</p> <p>In this example, we select from a table named 'albums', and fabricate a column 'name' to hold the values. These will be returned in the 'Album' model object. Change any of these names to suit your needs.</p> <pre><code>Album.find_by_sql("SELECT DISTINCT SUBSTR(name,1,1) AS 'name' FROM albums ORDER BY 1") </code></pre> <p>Note that you can't use the Album model objects for <em>anything</em> except querying the 'name' field. This is because we've given this object a lobotomy by only populating the 'name' field - there's not even a valid 'id' field associated!</p>