You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ibatis.apache.org by "Larry Meadors (JIRA)" <ib...@incubator.apache.org> on 2005/06/04 00:41:51 UTC

[jira] Updated: (IBATIS-125) Add ability to manually mark session dirty

     [ http://issues.apache.org/jira/browse/IBATIS-125?page=all ]

Larry Meadors updated IBATIS-125:
---------------------------------

    Description: 
We recently upgraded to 2.0.9b from 2.0.4. The one breaking change was that SqlMapSessionImpl's session field was changed from public to protected. While I understand and support this change, it makes it impossible for us to use stored procedures that do both an update and a select. Using update() means we can't return a result set, and using queryForObject/List means the transaction won't get committed (because setCommitRequired(true) is not called), so the update doesn't work.

It would be great if you could expose the following method on SqlMapSessionImpl:

public void setCommitRequired(boolean required) {
  this.session.setCommitRequired(true);
}

I think this is probably preferable to adding a queryAndUpdate method, since that type of operation is rare (and probably not encouraged).

  was:
We recently upgraded to 2.0.9b from 2.0.4. The one breaking change was that SqlMapSessionImpl's session field was changed from public to protected. While I understand and support this change, it makes it impossible for us to use stored procedures that do both an update and a select. Using update() means we can't return a result set, and using queryForObject/List means the transaction won't get committed (because setCommitRequired(true) is not called), so the update doesn't work.

It would be great if you could expose the following method on SqlMapSessionImpl:

public void setCommitRequired(boolean required) {
  this.session.setCommitRequired(true);
}

I think this is probably preferable to adding a queryAndUpdate method, since that type of operation is rare (and probably not encouraged).

        Version:     (was: 2.0.9b)
       Priority: Minor  (was: Major)

Changing priority to minor because there is a simple workaround.

> Add ability to manually mark session dirty
> ------------------------------------------
>
>          Key: IBATIS-125
>          URL: http://issues.apache.org/jira/browse/IBATIS-125
>      Project: iBatis for Java
>         Type: New Feature
>   Components: SQL Maps
>  Environment: All
>     Reporter: John Didion
>     Priority: Minor

>
> We recently upgraded to 2.0.9b from 2.0.4. The one breaking change was that SqlMapSessionImpl's session field was changed from public to protected. While I understand and support this change, it makes it impossible for us to use stored procedures that do both an update and a select. Using update() means we can't return a result set, and using queryForObject/List means the transaction won't get committed (because setCommitRequired(true) is not called), so the update doesn't work.
> It would be great if you could expose the following method on SqlMapSessionImpl:
> public void setCommitRequired(boolean required) {
>   this.session.setCommitRequired(true);
> }
> I think this is probably preferable to adding a queryAndUpdate method, since that type of operation is rare (and probably not encouraged).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira