You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@openjpa.apache.org by "Fernando (JIRA)" <ji...@apache.org> on 2008/11/26 19:18:44 UTC
[jira] Commented: (OPENJPA-790) queryImpl.setUnique can't be used
with read-only mode
[ https://issues.apache.org/jira/browse/OPENJPA-790?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12651085#action_12651085 ]
Fernando commented on OPENJPA-790:
----------------------------------
also, whilre you're at it.. you can clean up the " _unique = (unique) ? Boolean.TRUE : Boolean.FALSE; ".
Now that there is autoboxing:
_unique = unique;
> queryImpl.setUnique can't be used with read-only mode
> -----------------------------------------------------
>
> Key: OPENJPA-790
> URL: https://issues.apache.org/jira/browse/OPENJPA-790
> Project: OpenJPA
> Issue Type: Bug
> Components: kernel
> Affects Versions: 2.0.0
> Reporter: Fernando
> Priority: Minor
>
> for some reason, the setUnique method is making sure that it's not ReadOnly..
> But I would assume that setUnique is only called for select queries.. so it should only be for read-only queries.. they have nothing to do with update/delete right??
> kernel/QueryImpl.java
> public void setUnique(boolean unique) {
> lock();
> try {
> assertOpen();
> assertNotReadOnly();
> _unique = (unique) ? Boolean.TRUE : Boolean.FALSE;
> } finally {
> unlock();
> }
> }
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.