Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
有没有办法让 Sequel 返回模型而不是原始 sql 的哈希?
class Post < Sequel::Model def self.recent db["some sql goes here"].all #would like models returned here instead end end
希望这是有道理的。
class Post < Sequel::Model def self.recent with_sql("some sql goes here").all end end