Background Image

FORUM

조회 수 219 추천 수 0 댓글 1
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄


* 질문 등록 시 다음의 내용을 꼭 기입하여 주세요.

OS
Window7 32bit, Linux 64bit 등
CUBRID Ver.
[cubrid_rel] 수행 결과
CUBRID TOOL Ver.
[도움말]-[버전정보] 확인
응용 환경(API)
java, php, odbc 등 입력


* CUBRID 응용 오류, SQL 오류 또는 SQL 튜닝 관련된 문의는 반드시 다음의 내용을 추가해 주세요. 비밀글이나 비밀 댓글도 가능합니다.
* 저희가 상황을 이해하고, 재현이 가능해야 알 수 있는 문제들이 많습니다. 가능한 정보/정황들을 부탁합니다.

 

에러 내용 및 재현 방법 재현 가능한 Source와 SQL
관련 테이블(인덱스, 키정보 포함) 정보 CUBRID 홈 디렉토리 아래 log 디렉토리 압축


-------------- 아래에 질문 사항을 기입해 주세요. ------------------------------------------------------------------------
 

이미지를 저장하고 있는 컬럼인데

 

cubrid 는 BLOB Type이고 MS-SQL은 varbinary 타입입니다.

 

C#프로그램을 이용 cubrid의 Data를 읽어 와서 MS-SQL에 INSERT하는 프로그램을 구현했습니다.

 

                        CUBRIDBlob bImage = (CUBRIDBlob)dr["PHOTO_NM"];

                        byte[] bytes = new byte[(int)bImage.BlobLength];
                        bytes = bImage.GetBytes(1, (int)bImage.BlobLength);

 

이렇게 구현 했는데 오류가 발생합니다. 

왜 그런지 알 수 있을까요?

 

그리고 어떻게 하면 MS-SQL에 INSERT가능 한지도 알고 싶습니다.

 

오류는 아래와 같이 발생합니다.

 

오류발생:
CUBRID.Data.CUBRIDClient.CUBRIDException (0x80004005): Invalid connection handle
   위치: CUBRID.Data.CUBRIDClient.CUBRIDBlob.GetBytes(Int64 pos, Int32 length)
   위치: IPA.RFID.DBSync.App.classes.DownloadSyncProcess.TB_T_PROPOSAL_PHOTO(String dataGubun) 파일 D:\source\IPA.Solutioin\IPA.RFID.DBSync.App\classes\DownloadSyncProcess.cs:줄 728
 

추가

 

혹시 이거 DbDataReader 만 되고 DataRow는 안 되는 건가요? ㅠㅠ

 

  • ?
    오명환 2022.05.13 16:48
    답변이 늦었습니다.

    해당 오류는 잘못된 connection handle로 인한 exception입니다.
    https://github.com/CUBRID/cubrid-adonet/blob/develop/Code/Test/Functional/TestLOB.cs 코드를 보시면 DataReader 와 DataRow에서 읽어오는 코드들이 있습니다.
    코드 작성시 참조해보세요.

  1. CUBRID 사용자를 위한 DBeaver 도구 출시 안내

    Date2024.04.23 Byadmin Views47
    read more
  2. SQLGate for CUBRID 영구 무료 라이선스 제공

    Date2020.04.09 Byadmin Views4458
    read more
  3. restoredb 관련하여 코드셋 문제 문의

    Date2022.06.03 By플레이어블 Views117
    Read More
  4. TimeZone 관련 질문

    Date2022.06.03 Bysteve Views145
    Read More
  5. 큐브리드 내보내기 관련하여 문의드립니다.

    Date2022.06.03 Byghd129 Views137
    Read More
  6. cubrid는 처음 써보는데 궁금한 점이 있네요

    Date2022.05.31 Byyong4 Views111
    Read More
  7. ODBC SQLBindParameter ArrayLoad시, 쓰레기값이 붙어 나오는 현상

    Date2022.05.31 Byjhlee Views135
    Read More
  8. loaddb명령으로 sql파일 입력시 pk의 데이터가 중복일 경우에 대한 대처가 가능한 명령문을 알려주시면 감사하겠습니다.

    Date2022.05.18 By영웅찬 Views224
    Read More
  9. 함수 문의

    Date2022.05.18 Byamostella Views164
    Read More
  10. 복구가 일부만 되었습니다.

    Date2022.05.16 By도우너19 Views182
    Read More
  11. 큐브리드 ha master-replica 구성시 clob 필드가 업데이드 되지 않는 거 같습니다.

    Date2022.05.16 Bysamsam Views139
    Read More
  12. 큐브리드 백업과 삭제 cron 자동 설정

    Date2022.05.16 By도우너19 Views219
    Read More
  13. Program 'spacedb' (pid 5835) was connected from the host 'localhost.localdomain'

    Date2022.05.16 By도우너19 Views158
    Read More
  14. cubrid tool 문의

    Date2022.05.13 Byamostella Views67
    Read More
  15. 큐브리드 ha 구성 중에 master DB가 올라오지 않습니다.

    Date2022.05.12 Bysamsam Views306
    Read More
  16. 안녕하세요 큐브리드 재설치 후 '가져오기' 및 INSERT된 데이터 오류 문의드립니다.

    Date2022.05.12 By큐브짱 Views142
    Read More
  17. 날짜 형식 변환

    Date2022.05.11 By밍아 Views82
    Read More
  18. terminate called after throwing an instance of 'std::bad_alloc'

    Date2022.05.11 By영웅찬 Views276
    Read More
  19. hb_thread_check_disk_failure 오류 문의 드립니다.

    Date2022.05.11 By큐브짱 Views188
    Read More
  20. c# cubrid -> mssql BLOB type 데이타 전환

    Date2022.05.09 By알고싶다! Views219
    Read More
  21. 큐브리드 SYSDATETIME 문의 드립니다.

    Date2022.05.06 By큐브리드궁금 Views98
    Read More
  22. [Cubrid HA] restoreslave 사용할 경우 Master/Slave 경로를 반드시 동일하게 맞춰야하나요?

    Date2022.05.06 By큐브짱 Views71
    Read More
Board Pagination Prev 1 ... 14 15 16 17 18 19 20 21 22 23 ... 200 Next
/ 200

Contact Cubrid

대표전화 070-4077-2110 / 기술문의 070-4077-2113 / 영업문의 070-4077-2112 / Email. contact_at_cubrid.com
Contact Sales