Ruby on Rails: getting the max value from a DB column

后端 未结 2 908
北荒
北荒 2021-02-02 04:59

Currently I can make the straight-up SQL query on my DB:

SELECT MAX(bar) FROM table_name

And it returns

2条回答
提交回复
热议问题