@all = Player.find_by_sql(["SELECT u.id, u.name, UNIX_TIMESTAMP(u.last_active) AS last_active, UNIX_TIMESTAMP()- UNIX_TIMESTAMP(u.last_active) AS time_difference, r.status FROM players u LEFT JOIN guild_ranks r ON r.player_id=u.id AND r.guild_id=? WHERE u.guild_id=? ORDER BY r.status, u.level DESC", guild, guild])
I even tried adding attr_accessor :time_difference in Player class. I tried @all.map! but that didn't work either =/ -- You received this message because you are subscribed to the Google Groups "DataMapper" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/datamapper?hl=en.
