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.
grails からデータベース関数を呼び出すにはどうすればよいですか? 次のようなCONVERT(decimal, timestamp) groovy SQL を使用しない場合など:
CONVERT(decimal, timestamp)
def sql = new Sql(dataSource)
SQL ステートメントを一切使用せず、grails の魔法を最大限に活用したいと考えています。
私の理解では、grails はデータベース機能をネイティブでサポートしていません。SQL を記述する必要があります。Gorm は Hibernate の抽象化です。以下を参照してください。
Hibernate でカスタム データベース関数を呼び出すにはどうすればよいですか?