database.sarang.net
UserID
Passwd
Database
DBMS
MySQL
PostgreSQL
Firebird
Oracle
Informix
Sybase
MS-SQL
ㆍDB2
Cache
CUBRID
LDAP
ALTIBASE
Tibero
DB 문서들
스터디
Community
공지사항
자유게시판
구인|구직
DSN 갤러리
도움주신분들
Admin
운영게시판
최근게시물
DB2 Q&A 1307 게시물 읽기
No. 1307
SENSITIVE 커서 "SQL_CURSN300C1"은(는) 지정된 SELECT문에 정의할 수 없습니다.
작성자
초보자
작성일
2007-04-10 13:36
조회수
9,326

오라클 버전에서 DB2로 변환하고 있는데 "SENSITIVE 커서 "SQL_CURSN300C1"은(는) 지정된 SELECT문에 정의할 수 없습니다."라는 에러 메세지가 뜨네요.


select a.code1 as code1, a.code2 as code2, a.code3 as code3, a.code4 as code4,a.code_name as code_name,

       a.flag as flag,a.update_id as update_id,a.update_dt as update_dt,b.member_kor_name as update_name

from code a,member b

where a.code1 <> '0'

and a.code2 = '0'

and a.update_id = b.member_id

order by a.code_name


입니다.

이 sql을 다음과 같이 수정하니 오류는 안납니다.

뭐가 문제인가요?


select code1,code2,code3,code4,code_name,flag,update_id,update_dt,'' as member_kor_name 

from code 

where code1<>'0' 

and code2='0' 

order by code_name

이 글에 대한 댓글이 총 1건 있습니다.
JOIN 된결과는 READ ONLY이고,
SENSITIVE 커서는 READ ONLY로 OPEN할수없는듯합니다.

참고하세요.

SENSITIVE

Specifies that changes made to the database after the result table is
materialized are visible to the cursor. The cursor has some level of 
sensitivity to any updates or deletes made to the rows underlying its
result table after the table is materialized. The cursor is always
sensitive to positioned updates or deletes using the same cursor.
Additionally, the cursor can have sensitivity to committed changes
made outside this cursor.

If DB2 cannot make changes visible to the cursor, then an error is
issued at bind time for OPEN CURSOR. DB2 cannot make changes visible
to the cursor when the cursor implicitly becomes read-only. Such is
the case when the result table must be materialized, as when the FROM
clause of the SELECT statement contains more than one table or view.


DB2 UDB for OS/390 and z/OS V7 SQL Reference 영문메뉴얼
http://publib.boulder.ibm.com/cgi-bin/bookmgr/BOOKS/dsnsqh16/CCONTENTS

DB2 UDB for OS/390 and z/OS V8 SQL Reference 영문메뉴얼
http://publib.boulder.ibm.com/cgi-bin/bookmgr/BOOKS/dsnsqj13/CCONTENTS


박진복(pjb708)님이 2007-04-10 16:28에 작성한 댓글입니다.
이 댓글은 2007-07-03 15:35에 마지막으로 수정되었습니다.
[Top]
No.
제목
작성자
작성일
조회
1310데이타베이스 복구방법
미리내
2007-04-11
7250
1309rownumber() 대신 사용할수 있는것좀 알려주세요. [1]
무명
2007-04-11
10008
1308DB2 서버가 2대인 경우에...
DB2사랑
2007-04-11
7525
1307SENSITIVE 커서 "SQL_CURSN300C1"은(는) 지정된 SELECT문에 정의할 수 없습니다. [1]
초보자
2007-04-10
9326
1304Error: SQL0104 - Token DCCONT1 was not valid. Valid tokens: NO FOR NOT FILE WITH CCSID CHECK UNIQUE DEFAULT PRIMARY. (State:37000, Native Code: FFFFFF98)에러요!! [1]
윤진수
2007-04-06
8499
1303substr 오류 [1]
김은수
2007-04-05
8097
1302db2 명령이 실행이 안되는데.., [1]
김은수
2007-04-05
7460
Valid XHTML 1.0!
All about the DATABASE... Copyleft 1999-2024 DSN, All rights reserved.
작업시간: 0.020초, 이곳 서비스는
	PostgreSQL v16.2로 자료를 관리합니다