まにょのITメモ
×
[PR]上記の広告は3ヶ月以上新規記事投稿のないブログに表示されています。新しい記事を書く事で広告が消えます。
テンプレ1 =================================
<!-- $sampleTempBean.title -->
<insert id="insert${sampleTempBean.historyTableName}MANYO" parameterClass="java.util.Map">
INSERT /* insert${sampleTempBean.historyTableName}MANYO */
INTO ${sampleTempBean.historyTableName}
(
#foreach($columName in $sampleTempBean.columNameList)
#if($velocityCount == 1)
$columName
#else
, $columName
#end
#end
)
select
#historyKey# AS SAMPLE_KEY
, to_char(#timeStamp#, 'YYYYMMDD') AS SAMPLE_YMD
, to_char(#timeStamp#, 'HH24MISS') AS SAMPLE_TRS
, '' AS SAMPLECD
#foreach($columName in $sampleTempBean.columNameList)
, $columName
#end
, #sampleId# AS SAMPLE_USR
, #timeStampr# AS SAMPLE_YMD
, #updateUserId# AS SAMPLE_USR
, #timeStamp# AS SAMPLE_TSTNP
from
$sampleTempBean.tableName
where
SAMPLE_KEY = #sampleKey#
</insert>
テンプレ2============================
// $sampleTempBean.title
tmp1.insert("insert${sampleTempBean.historyTableName}MANYO", param);
<!-- $sampleTempBean.title -->
<insert id="insert${sampleTempBean.historyTableName}MANYO" parameterClass="java.util.Map">
INSERT /* insert${sampleTempBean.historyTableName}MANYO */
INTO ${sampleTempBean.historyTableName}
(
#foreach($columName in $sampleTempBean.columNameList)
#if($velocityCount == 1)
$columName
#else
, $columName
#end
#end
)
select
#historyKey# AS SAMPLE_KEY
, to_char(#timeStamp#, 'YYYYMMDD') AS SAMPLE_YMD
, to_char(#timeStamp#, 'HH24MISS') AS SAMPLE_TRS
, '' AS SAMPLECD
#foreach($columName in $sampleTempBean.columNameList)
, $columName
#end
, #sampleId# AS SAMPLE_USR
, #timeStampr# AS SAMPLE_YMD
, #updateUserId# AS SAMPLE_USR
, #timeStamp# AS SAMPLE_TSTNP
from
$sampleTempBean.tableName
where
SAMPLE_KEY = #sampleKey#
</insert>
テンプレ2============================
// $sampleTempBean.title
tmp1.insert("insert${sampleTempBean.historyTableName}MANYO", param);
PR
この記事にコメントする