psql + get the last rows in a table code example
Example: postgres get last value
select last_value("name") over(order by created_at desc) as name from profile
select last_value("name") over(order by created_at desc) as name from profile