db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Anurag Shekhar (JIRA)" <j...@apache.org>
Subject [jira] Commented: (DERBY-3330) provide support for unique constraint over nullable columns
Date Mon, 18 Feb 2008 19:16:34 GMT

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

Anurag Shekhar commented on DERBY-3330:
---------------------------------------

Thanks Mike for pointing out the possibility of having empty page and hence need to scan multiple
page. 
I will reintroduce the code for the same. I will add code to keep moving left (or right) till
a row is found or no more leaf is available. 

Locking of left or right row is attempted only if there is a duplicate is found. In that case

a. The transaction was deleted in same transaction -- So its already locked within same transaction
b. Is deleted in some other transaction - It will result in losing the latch and a rescan
will performed to identify the slot (no lock)

c. Is an valid row - an exception will be thrown and lock will be released immediately.


Irrespective of the isolation level only update lock is requested. But the actual locking
is performed only in case c and that too for a very short time, I think it won't have much
impact on performance. 

> provide support for unique constraint over nullable columns
> -----------------------------------------------------------
>
>                 Key: DERBY-3330
>                 URL: https://issues.apache.org/jira/browse/DERBY-3330
>             Project: Derby
>          Issue Type: New Feature
>          Components: Store
>    Affects Versions: 10.4.0.0
>         Environment: all
>            Reporter: Anurag Shekhar
>            Assignee: Anurag Shekhar
>         Attachments: BTreeController.diff, derby-3330-testcase.diff, derby-3330.diff,
derby-3330v2.diff, derby-3330v3.diff, derby-3330v4.diff, derby-3330v5.diff, FunctionalSpec_DERBY-3330-V2.html,
FunctionalSpec_DERBY-3330.html, UniqueConstraint_Implementation.html
>
>
> Allow unique constraint over nullable field. Right now derby support unique constraint
only over not null columns.

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


Mime
View raw message