일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | 6 | 7 |
8 | 9 | 10 | 11 | 12 | 13 | 14 |
15 | 16 | 17 | 18 | 19 | 20 | 21 |
22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 |
- jsp
- 시작하기
- s4a
- 설치
- librecad
- 아두이노
- 강좌
- 예제
- 운정
- 설정
- 유니티
- MSSQL
- jobtoy
- tomcat
- Unity
- 코딩
- 잡토이 메이킹 코딩 학원
- html5
- 스크래치
- mysql
- 파주
- 리브레캐드
- Android
- Spring Security
- 톰캣
- oracle
- 잡토이
- 안드로이드
- 오라클
- 라즈베리파이
- Today
- Total
랩제이
[ibaitis] mysql select PROCEDURE 본문
[ibaitis] mysql select PROCEDURE ibatis
코드1)
- java
@Override
public List<Etraininglist> selectEtraininglistList(int code) throws Exception {
logger.debug("selectEtraininglistList -------------------------->> " + code);
Map<String, Object> condition = new HashMap<String, Object>();
condition.put("code", code);
return sqlMap.queryForList("member.selectEtraininglist", condition);
}
- ibatis
<parameterMap class="map" id="selParam">
<parameter property="code" jdbcType="INT" javaType="java.lang.Integer" mode="IN"/>
</parameterMap>
<procedure id="selectEtraininglist" parameterMap="selParam" resultClass="Etraininglist" >
<![CDATA[
{CALL USP_Interface_Member_GetEducationCourceByButton(?)}
]]>
</procedure>
코드2)
- java
@Override
public List<Etraininglist> selectEtraininglistList(int code) throws Exception {
logger.debug("selectEtraininglistList -------------------------->> " + code);
return sqlMap.queryForList("member.selectEtraininglist", code);
}
- ibatis
<procedure id="selectEtraininglist" parameterClass="java.lang.Integer" resultClass="Etraininglist" >
<![CDATA[
{CALL USP_Interface_Member_GetEducationCourceByButton(#code#)}
]]>
</procedure>
[ibaitis] mysql select PROCEDURE ibatis
'programming > ibatis mybatis' 카테고리의 다른 글
[mybatis] oracle insert 리턴값 받기 selectKey (0) | 2014.10.23 |
---|---|
[mybatis] function 호출하고 리턴값 받기 (0) | 2014.08.04 |
[ibatis] in 조건 생성하기 (0) | 2013.10.17 |
[ibatis] in 조건으로 delete 하기 (0) | 2013.10.02 |
[ibatis] delete sql in 사용 (0) | 2013.06.30 |