This is a cache of http://dbflute.seasar.org/ja/manual/function/ormapper/outsidesql/index.html. It is a snapshot of the page at 2025-04-29T00:03:57.961+0000.
外だし<strong>s</strong>QL(Out<strong>s</strong>ide<strong>s</strong>ql) | DBFlute

外だしsQL(Outsidesql)

外だしsQLの基本

外だしsQLについて
外だしsQLとは?最大の特徴である 2Way-sQL, パラメータコメント など
外だしsQLの使い方
外だしsQLの作成方法や手順など ※わからなくなったらとりあえずここ
  1. 外だしsQLを パラメータコメント を使って 2Way-sQL で書く
  2. sql2Entity を実行して CustomizeEntityParameterBean を自動生成
  3. Behaviorの outsidesql() メソッドから実行

外だしsQLの機能

select
検索系
selectList()
リスト検索
entityHandling().selectEntity()
一件検索(結果がない場合はnullを戻す)
entityHandling().selectEntityWithDeletedCheck(cb)
一件検索(結果がない場合は例外発生)
manualPaging().selectPage()
手動のページング検索
autoPaging().selectPage()
自動のページング検索
cursorHandling().selectCursor()
カーソル検索
Likesearch
Likesearch条件(曖昧検索) - new LikesearchOption().likePrefix()
Update
更新系
execute()
更新系sQLの実行
Procedure
プロシージャ
call()
プロシージャコール
Option
オプション系
configure() (statementConfig)
statementのConfiguration(queryTimeoutなど)
dynamicBinding().select...()
動的バインディング検索
removeBlockComment().select...()
実行時のブロックコメントの削除
removeLineComment().select...()
実行時の行コメントの削除
formatsql().select...()
実行時のsQLのフォーマット(空行の削除など)

外だしsQLのExample

外だしsQLの Example プロジェクトがありますのでぜひ参考に。

DBFlute Example - 基本的な HowTo