Active Records with column privilages

Hey I am making applications that has different DB roles to the same
database. One is pretty much the admin access where the person can see
all the columns in each table, then there is the regular joe DB role
where I don’t let him see confidential information that only admin can
see, for security purposes, so I put column privileges on that role. The
problem with that is the fact that Rails do not see these privileges set
by the DB and Rails gets all the columns in a table. I do not want it to
do that. I wish to prevent those columns from showing in the model. Is
this possible?

nvm, i checked out ActiveRecord::Base and I found no such thing. But I
did find a nice patch that was made 2 years ago

I changed it around to this to match the the code in rails 2.2.2

   # Hide columns from active record
   def attr_hidden(*attributes)
     write_inheritable_attribute(:attr_hidden, + (hidden_attributes || []))

   def hidden_attributes # :nodoc:

and changed ActiveRecord::Base.column ofcourse

  # Returns an array of column objects for the table associated with 

this class.
def columns
unless defined?(@columns) && @columns
@columns = connection.columns(table_name, “#{name}
Columns”).delete_if {|c| attr_hidden.member?(}
@columns.each { |column| column.primary = ==
primary_key }

wish something like this is implemented. in my mind it is pretty useful.
Ofcourse i do wish it could be a lil bit more automated by looking into
the DB for the column privileges, but this is cool. =D