Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-6347727

Connection create/prepareStatement/Call() holdability should be clarified

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P4 P4
    • 6
    • 5.0
    • core-libs
    • b63
    • sparc
    • solaris_10

      A DESCRIPTION OF THE REQUEST :
      Documentation for Connection methods createStatement() , createStatement(int resultSetType, int resultSetConcurrency), prepareStatement(String sql) , prepareStatement(String sql, int resultSetType, int resultSetConcurrency), prepareStatement(String sql, int autoGeneratedKeys), prepareStatement(String sql, int[] columnIndexes), prepareStatement(String sql, String[] columnNames), prepareCall(String sql) and prepareCall(String sql, int resultSetType, int resultSetConcurrency) needs to be clarified because it does not specify holdability of the result set created by the returned statements.


      JUSTIFICATION :
      These methods' documentation specifies both default type and concurency level, but not holdability for the result sets created. Is is a problem especially if driver does not implement getHoldability().

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      Documentation for these methods should state that result sets holdability is defined for the Connection instance by setHoldability() and can be obtained by getHoldability(). It should also state what is the default if setHoldability() has not been called or is not supported, or if that it could vary over driver implementations if no default is enforced by specifications (but I think it should be enforced, at least for driver that does not support getHoldability/setHoldability, or otherwise it should clarified in commit() method documentation that no assumption can be made about the cursors state after commit).

      ACTUAL -
      No documentation about what is the default holdability.

            lancea Lance Andersen
            gmanwanisunw Girish Manwani (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: