iBatis에서 Oracle CLOB, BLOB 넣고 빼기
우선 자바빈의 경우
우선 자바빈의 경우
- class Data{
- byte[] blobField;
- String clobField;
- }
데이터 Insert시 insert into table values( #blobField:BLOB#, #clobField:CLOB#) 로 넣으면 됨. 파리미터 맵을 써도 됨.
데이터 select 시 select blob, clob from table에서 resultClass로는 안 받아짐.
따로 resultMap을 써서 아래와 같은 매핑이 필요
<resultMap id="result" class="beanClassName">
<result property="clobField" column="clobField" jdbcType="CLOB"/>
<result property="blobField" column="blobField" jdbcType="BLOB"/>
</resultMap>
'Language > C#' 카테고리의 다른 글
집합쿼리 union, intersect, minus (0) | 2016.02.04 |
---|---|
oracle odp.net설치 없이 배포하기 (0) | 2016.02.04 |
각 DB별 ConnectionString 정리 (0) | 2016.02.04 |
ORA-39095: Dump file space has been exhausted: Unable to allocate 8192 bytes (0) | 2016.02.04 |
킬로바이트 메가바이트 기가바이트 테라바이트 계산기: KB MB GB TB PB 환산 Convert (0) | 2016.02.04 |