Background Image

FORUM

2010.02.03 02:44

오류구문이 뜹니다.

조회 수 11738 추천 수 0 댓글 3
?

단축키

Prev이전 문서

Next다음 문서

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

function sql_prepare($sql, $params)
{
 global $conn;

 $req = cubrid_prepare( $conn, $sql ); //, CUBRID_INCLUDE_OID );
 $i = 1;
 //echo print_r($params)."<Br>";
 foreach ($params as &$p) {
  $res = cubrid_bind($req, $i, $p);
  $i++;
 }
 return $req;
}

$sql = select * from board a, category b where a.board=b.board and a.id = b.id and a.board= ? and a.id not in ( 249,248,247 ) order by num desc, reply asc for orderby_num() between ? and ?
$params = Array ( "cool", 0, 35 )

$req = sql_prepare($sql, $params);
cubrid_execute($req);
while ($rs = cubrid_fetch($req))  <========= 이줄에서 오류가 납니다.

오류 메세지 :
Warning: Error: DBMS, -447, An operation has been attempted on a closed query result structure. in c:board.php on line 196 Loading...

데이타는 잘 나오는데 무슨오류죠?

  • ?
    seongjoon 2010.02.04 00:31
    $sql = select * from board a, category b where a.board=b.board and a.id = b.id and a.board= ? and a.id not in ( 249,248,247 ) order by num desc, reply asc for orderby_num() between ? and ?
    $params = Array ( "cool", 0, 35 )
    위 내용에서  "나 ', 그리고 ;는 원래 없는 건가요?
    해당 sql 문장에서 사용된 쿼리의 스키마 정보를 올려주시면 문제 해결에 큰 도움이 될 것으로 보입니다.
  • ?
    초보 2010.02.04 00:49
    정확한 쿼리 내용 입니다.
    $sql = "select * board a, category b where a.code=b.code and a.id = b.id and a.code= ? and a.id not in ( 249,248,247 ) order by num desc, reply asc for orderby_num() between ? and ? ";
    $params = Array ( "cool", 0, 35 ) ;
    스키마는 다음과 같습니다.
    CREATE TABLE "board"(
    "id" integer NOT NULL,
    "code" character varying(40) DEFAULT  NOT NULL,
    "num" integer DEFAULT 0 NOT NULL,
    "reply" character varying(20) DEFAULT  NOT NULL,
    );

    CREATE TABLE "category"(
    "ca_id" integer AUTO_INCREMENT PRIMARY KEY,
    "code" character varying(20) DEFAULT  NOT NULL,
    "id" integer DEFAULT 0 NOT NULL,
    "ca_name" character varying(510) DEFAULT  NOT NULL
    );

  • ?
    남재우 2010.02.11 01:44
    안녕하세요.
    해당 내용에 대한 답변은 재질문하신 곳에 답변을 달아드렸습니다. 간단히 말씀드리면 select 질의에 from 이 없어 질의 prepare시 에러가 발생한 내용입니다.
    532번글 답변이 아직 없으셔서 다시 올립니다

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

    Date2024.04.23 Byadmin Views144042
    read more
  2. 서브쿼리 질문

    Date2010.02.03 By초보 Views14122
    Read More
  3. 큐브리드 매니져에서 정수 쿼리 16진수 표시

    Date2010.02.03 By소라게 Views15608
    Read More
  4. 오류구문이 뜹니다.

    Date2010.02.03 By초보 Views11738
    Read More
  5. 로그 분석 툴 이용시 분석 에러발생합니다.

    Date2010.02.03 By노스 Views13569
    Read More
  6. mysql 구문변환

    Date2010.02.03 By초보 Views13245
    Read More
  7. 매니저에 쿼리 오류 메세지가 갑자기 안나옵니다.

    Date2010.02.03 By초보 Views12528
    Read More
  8. data_buffer_page 를 300000 이상으로 늘렸더니

    Date2010.02.02 By초보 Views13413
    Read More
  9. 큐브리드 커넥션 유지 시간

    Date2010.02.02 By초보 Views13258
    Read More
  10. 서브쿼리 ORDERBY_NUM() 최적화 문제

    Date2010.01.29 Byasteroid Views16855
    Read More
  11. ADO이용시 OLEDB Driver에러

    Date2010.01.29 Byflypig Views18622
    Read More
  12. QTADO와 OLEDB사용시 문제

    Date2010.01.29 Byflypig Views13064
    Read More
  13. 큐브리드 매니저에서 서브쿼리 날리면 값이 안나오는 문제

    Date2010.01.29 By지니보이 Views13896
    Read More
  14. 리스트 목록 갯수

    Date2010.01.28 Bywebdoors Views14361
    Read More
  15. Linux Centso5.1에 설치 중입니다.

    Date2010.01.27 ByPhilip Park Views12090
    Read More
  16. CUBRID-8.2.1.0215 CentOs5.1에 설치 중입니다.

    Date2010.01.27 ByPhilip Park Views14051
    Read More
  17. 대용량 mysql 데이타를 큐브리드 2008 로 마이그레이션 할때

    Date2010.01.27 By초보 Views14088
    Read More
  18. 8.2.1버전에서 SQuirreL SQL Client 접속 가능한가요?

    Date2010.01.26 ByPhilip Park Views16365
    Read More
  19. php게시판에 있는 php설치 글에서.<? phpinfo.php ?>사용이 가능한 구문인가요?

    Date2010.01.26 By뚱기 Views37884
    Read More
  20. cubrid 6.6.0 제공 문의

    Date2010.01.25 By이종욱 Views7
    Read More
  21. 문자집합 변경에 대하여

    Date2010.01.25 By쭈난 Views14665
    Read More
Board Pagination Prev 1 ... 182 183 184 185 186 187 188 189 190 191 ... 213 Next
/ 213

Contact Cubrid

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