Try OpenEdge Now
skip to main content
DataServer for Oracle
Sample Queries : Query 6
 

Query 6

In Query 6 presented in this section, note the following points related to cursor behavior:
<2>   The DataServer uses the cursor to compare schema information. It does not fetch any column values.
<3>   The single lookahead cursor selects columns directly. It selects all columns because the query does not contain a field list.
FOR EACH customer NO-LOCK:
  DISPLAY customer.name customer.custnum customer.postal-code.
END.
OCI call OCIStmtPrepare <2> sqlcrc = 41633
SELECT /*+ INDEX(T0 CUSTOMER##PROGRESS_RECID) */ * FROM DOCTEST.C
USTOMER T0 WHERE PROGRESS_RECID = :rid
OCI call OCIStmtExecute-DescribeOnly <2>
OCI call omru <2>
OCI call OCIHandleAlloc <0>
OCI call OCIStmtPrepare <3> sqlcrc = 60425
SELECT /*+ INDEX_ASC(T0 CUSTOMER##CUST_NUM) */ PROGRESS_RECID un
ique_id_0,CUST_NUM,COUNTRY,NAME,ADDRESS,ADDRESS2,CITY,STATE,POSTA
L_CODE,CONTACT,PHONE,SALES_REP,CREDIT_LIMIT,BALANCE,TERMS,DISCOUN
T,COMMENTS,PROGRESS_RECID FROM DOCTEST.CUSTOMER T0
OCI call OCIStmtExecute <3>
OCI call OCIStmtFetch <3>
OCI call OCIStmtFetch <3>
OCI call OCIStmtFetch <3>
OCI call OCIStmtFetch <3>
OCI call OCIStmtFetch <3>
OCI call omru <3>
Cursor <3> Rows processed 85 (last execution)
Number of array fetches 5
Number of rows fetched 85
Number of array rows 17
Number of array columns 18
Number of tables 1
Space for one row 472
Requested cache size 8192
Actual cache size used 8024
OCI call OCIHandleFree <0>
Cursor <2> Rows processed 0 (last execution)
OCI call OCIHandleFree <0>