From: Joey Date: 2006-05-22T18:20:04+09:00 Subject: Re: converting class or type under single table inheritance ------=_Part_16816_342763.1148289602021 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Content-Disposition: inline user[:type] =3D AdminUser On 5/22/06, Levent Ali wrote: > > I think this query is more Ruby than Rails but I'm writing a Rails app > using single table inheritance > > class User < ActiveRecord::Base > end > > class AdminUser < User > end > > The type column in the users table holds the class name for each > instance > > Now I want to convert a User object into an AdminUser. Is this > possible? Does anyone know the best way to do this? > > Thanks in advance > levent > > -- > Posted via http://www.ruby-forum.com/. > > ------=_Part_16816_342763.1148289602021--