[ 
https://issues.apache.org/jira/browse/DERBY-3801?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12898500#action_12898500
 ] 

Myrna van Lunteren commented on DERBY-3801:
-------------------------------------------

Hi Yun,

Those are good finds.

The difference is in the data - in the holdCursorIJ.sql test, there are only 2 
tiny rows in the table.
In the junit tests, the tables both have many rows. The prefetching is done in 
chunks of 32K.
So, in the ij test, the entire table is prefetched by the server; in the junit 
tests you found, the prefetch is done, but there's more data, so the cursor 
must stay open.

(I verified the behavior by making a copy of the two fixtures you found, but 
with the following table:
create table smallt1 (c1 int, c2 int);
insert into smallt1 values(1, 1);
insert into smallt1 values(2, 2);
and indeed, the tests then failed for network server, indicating no error was 
thrown).

Thus, the difference is not a bug, and as you found areas where they're being 
tested, you can safely remove those test cases from the HoldCursorIJ script.


> Convert "org.apache.derbyTesting.functionTests.tests.lang.holdCursorIJ.sql" 
> to junit. 
> --------------------------------------------------------------------------------------
>
>                 Key: DERBY-3801
>                 URL: https://issues.apache.org/jira/browse/DERBY-3801
>             Project: Derby
>          Issue Type: Improvement
>          Components: Test
>            Reporter: Junjie Peng
>            Assignee: Yun Lee
>         Attachments: derby-3801-1-patch.txt, derby-3801-2.patch, 
> derby-3801-2.stat, derby-3801-4.patch, derby-3801-5.patch, derby-3801-5.stat, 
> derby-3801-6.patch, derby-3801-6.stat, DERBY-3801-Tiago.patch
>
>
> Convert "org.apache.derbyTesting.functionTests.tests.lang.holdCursorIJ.sql" 
> to junit. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to