Background Image

FORUM

2010.02.03 02:44

오류구문이 뜹니다.

조회 수 8841 추천 수 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 Views48
    read more
  2. SQLGate for CUBRID 영구 무료 라이선스 제공

    Date2020.04.09 Byadmin Views4458
    read more
  3. 오라클의 LAG (위 Row 값), LEAD (아래 Row 값) 가져올수 있는 쿼리 대체할만한것이 있나요?

    Date2015.03.29 By거만고양이 Views12419
    Read More
  4. 오라클의 Aggregation Function(집합 함수) 관련 문의

    Date2013.11.14 By샤방석이 Views24635
    Read More
  5. 오라클의 SUBSTRB 기능 문의

    Date2023.12.26 By방글이 Views110
    Read More
  6. 오라클의 USER_CONSTRAINTS

    Date2013.10.28 Byagkim Views9283
    Read More
  7. 오라클의 contains()문과 비슷한 기능을 소개해주세요

    Date2009.02.17 By타이거팀 Views36302
    Read More
  8. 오라클의 listagg 기능이 큐브리드에 있을까요?

    Date2018.11.21 By위니텍 Views1260
    Read More
  9. 오라클의 with 테이블명 as 구문은 큐브리드에서 사용이 안되는지요?

    Date2017.04.06 By최범규 Views9218
    Read More
  10. 오류 관련 문의 드립니다.

    Date2015.05.27 By아코 Views10
    Read More
  11. 오류 관련 문의 드립니다.

    Date2015.05.28 By아코 Views11
    Read More
  12. 오류 꼭 좀 도와주세요 ㅠㅠ

    Date2010.08.25 By딩이 Views9852
    Read More
  13. 오류 메세지 문의 Derived column names are not allowed for simple class specifications.

    Date2023.12.01 By달이맘 Views125
    Read More
  14. 오류 좀 봐주세요...ㅜㅜ

    Date2016.07.01 By반갑습니다 Views15
    Read More
  15. 오류 좀 확인해주세요ㅜㅜ

    Date2009.12.04 By푸른잔디 Views21923
    Read More
  16. 오류 코드 관련 문의

    Date2013.02.12 By........ Views5819
    Read More
  17. 오류 해결방법을 몰라 질문드립니다.

    Date2012.05.16 By삼구 Views11307
    Read More
  18. 오류 확인 부탁합니다,

    Date2020.07.02 By배철 Views734
    Read More
  19. 오류(연결을 얻을수 없습니다.)

    Date2011.03.25 By맑고푸른하늘 Views12002
    Read More
  20. 오류가 이런게나서 이중화 한쪽이 안올리가는데 무슨에런 인가요?

    Date2017.12.09 Bycoolkkm Views595
    Read More
  21. 오류구문이 뜹니다.

    Date2010.02.03 By초보 Views8841
    Read More
  22. 오류번호 -677

    Date2020.08.11 Bybchlim Views357
    Read More
Board Pagination Prev 1 ... 139 140 141 142 143 144 145 146 147 148 ... 200 Next
/ 200

Contact Cubrid

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