ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aki Kubota <axkub...@yahoo.com>
Subject short cut to <INSERT>
Date Thu, 26 May 2005 07:08:51 GMT
I have this code...

   <typeAlias alias="keyword"
type="com.mvl.domain.Keyword"/>
        
    <resultMap id="keywordMap" class="keyword">
        <result property="keywordId"
column="KEYWORD_ID"/>
        <result property="keyword" column="KEYWORD"/>
        <result property="partOfSpeech"
column="PART_OF_SPEECH"/>
        <result property="icon" column="ICON"/>
        <result property="definition1"
column="DEFINITION_1"/>
        <result property="definition2"
column="DEFINITION_2"/>
        <result property="visualSuggn1"
column="VISUAL_SUGGESTION_1"/>
        <result property="visualSuggn2"
column="VISUAL_SUGGESTION_2"/>
        <result property="flashFile"
column="FLASH_FILE"/>
        <result property="soundFileNorm"
column="SOUND_FILE_NORM"/>
        <result property="soundFileSlow"
column="SOUND_FILE_SLOW"/>
    </resultMap>
    
    <insert id="insertKeyword"
parameterClass="keyword">
        insert into MVL_KEYWORD(
            KEYWORD_ID,
            KEYWORD,
            PART_OF_SPEECH,
            ICON,
            DEFINITION_1,
            DEFINITION_2,
            VISUAL_SUGGESTION_1,
            VISUAL_SUGGESTION_2,
            FLASH_FILE,
            SOUND_FILE_NORM,
            SOUND_FILE_SLOW)
        values (
            #keywordId#,
            #keyword#,
            #partOfSpeech#,
            #icon#,
            #definition1#,
            #definition2#,
            #visualSuggn1#,
            #visualSuggn2#,
            #flashFile#,
            #soundFileNorm#,
            #soundFileSlow#
            )
    </insert>

Is there a short cut to this in the SLQMAP? 
Someway to associate my resultMap or parameterMap
to my INSERT statement?


Thanks.



		
__________________________________ 
Do you Yahoo!? 
Yahoo! Small Business - Try our new Resources site
http://smallbusiness.yahoo.com/resources/

Mime
View raw message