find_by_sql timestamp parameter

In controller I have this query:

@price_stat = Price.find_by_sql("select id, cost, tour_id,
unix_timestamp(created_at) from prices")

when I try to display result's created_at column I don't have any

<% @price_stat.each do |p| %>
  <p><%= p.created_at %></p>
<% end %>

result is empty

But if I try without unix_timestamp. ie:

@price_stat = Price.find_by_sql("select id, cost, tour_id, created_at
from prices")

It works fine. ( <%= p.created_at %> )

How I can get value of created_at column when using unix_timestamp?

Thanks in advance

Because created_at is no longer in the select list - some column with
a different name is there instead. You should probably to something
like unix_timestamp(created_at) as unix_created_at in your select
clause (and then p.unix_created_at should be that value)