harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lvj...@apache.org
Subject svn commit: r642919 - in /harmony/enhanced/classlib/trunk/modules/sql/src: main/java/org/apache/harmony/sql/internal/rowset/JdbcRowSetImpl.java test/java/org/apache/harmony/sql/tests/internal/rowset/JdbcRowSetJoinTest.java
Date Mon, 31 Mar 2008 08:11:36 GMT
Author: lvjing
Date: Mon Mar 31 01:11:30 2008
New Revision: 642919

URL: http://svn.apache.org/viewvc?rev=642919&view=rev
Log:
Apply patch for HARMONY-5669, [classlib][sql][rowset] Implement Joinable in JoinRowSet

Added:
    harmony/enhanced/classlib/trunk/modules/sql/src/test/java/org/apache/harmony/sql/tests/internal/rowset/JdbcRowSetJoinTest.java   (with props)
Modified:
    harmony/enhanced/classlib/trunk/modules/sql/src/main/java/org/apache/harmony/sql/internal/rowset/JdbcRowSetImpl.java

Modified: harmony/enhanced/classlib/trunk/modules/sql/src/main/java/org/apache/harmony/sql/internal/rowset/JdbcRowSetImpl.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/sql/src/main/java/org/apache/harmony/sql/internal/rowset/JdbcRowSetImpl.java?rev=642919&r1=642918&r2=642919&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/sql/src/main/java/org/apache/harmony/sql/internal/rowset/JdbcRowSetImpl.java (original)
+++ harmony/enhanced/classlib/trunk/modules/sql/src/main/java/org/apache/harmony/sql/internal/rowset/JdbcRowSetImpl.java Mon Mar 31 01:11:30 2008
@@ -18,14 +18,19 @@
 
 import java.sql.SQLException;
 import java.sql.Savepoint;
+import java.util.Arrays;
 
 import javax.sql.rowset.JdbcRowSet;
 import javax.sql.rowset.RowSetWarning;
 
-import org.apache.harmony.luni.util.NotImplementedException;
+import org.apache.harmony.sql.internal.nls.Messages;
 
 public class JdbcRowSetImpl extends AbstractRowSetImpl implements JdbcRowSet {
 
+    private String[] matchColumnNames;
+
+    private int[] matchColumnIndexes;
+
     public void commit() throws SQLException {
         if (connection == null) {
             throw new NullPointerException();
@@ -73,43 +78,181 @@
     }
 
     public int[] getMatchColumnIndexes() throws SQLException {
-        throw new NotImplementedException();
+        if (matchColumnIndexes == null || matchColumnIndexes.length == 0
+                || matchColumnIndexes[0] == -1) {
+            // rowset.13=Set Match columns before getting them
+            throw new SQLException(Messages.getString("rowset.13")); //$NON-NLS-1$
+        }
+
+        return matchColumnIndexes.clone();
     }
 
     public String[] getMatchColumnNames() throws SQLException {
-        throw new NotImplementedException();
+        if (matchColumnNames == null || matchColumnNames.length == 0
+                || matchColumnNames[0] == null) {
+            // rowset.13=Set Match columns before getting them
+            throw new SQLException(Messages.getString("rowset.13")); //$NON-NLS-1$
+        }
+        return matchColumnNames.clone();
     }
 
     public void setMatchColumn(int columnIdx) throws SQLException {
-        throw new NotImplementedException();
+        if (columnIdx < 0) {
+            // TODO why is 0 valid?
+            // rowset.20=Match columns should be greater than 0
+            throw new SQLException(Messages.getString("rowset.20")); //$NON-NLS-1$
+        }
+
+        if (matchColumnIndexes == null) {
+            /*
+             * FIXME initial match column, the default length of array is 10 in
+             * RI, we don't know why, just follow now
+             */
+            matchColumnIndexes = new int[10];
+            Arrays.fill(matchColumnIndexes, -1);
+        }
+
+        matchColumnIndexes[0] = columnIdx;
     }
 
     public void setMatchColumn(int[] columnIdxes) throws SQLException {
-        throw new NotImplementedException();
+        if (columnIdxes == null) {
+            throw new NullPointerException();
+        }
+
+        for (int i : columnIdxes) {
+            if (i < 0) {
+                // TODO why is 0 valid?
+                // rowset.20=Match columns should be greater than 0
+                throw new SQLException(Messages.getString("rowset.20")); //$NON-NLS-1$
+            }
+        }
+
+        if (matchColumnIndexes == null) {
+            /*
+             * FIXME initial match column, the default length of array is 10 in
+             * RI, we don't know why, just follow now
+             */
+            matchColumnIndexes = new int[10];
+            Arrays.fill(matchColumnIndexes, -1);
+        }
+
+        int[] newValue = new int[matchColumnIndexes.length + columnIdxes.length];
+        System.arraycopy(columnIdxes, 0, newValue, 0, columnIdxes.length);
+        System.arraycopy(matchColumnIndexes, 0, newValue, columnIdxes.length,
+                matchColumnIndexes.length);
+
+        matchColumnIndexes = newValue;
     }
 
     public void setMatchColumn(String columnName) throws SQLException {
-        throw new NotImplementedException();
+        if (columnName == null || columnName.equals("")) { //$NON-NLS-1$
+            // rowset.12=Match columns should not be empty or null string
+            throw new SQLException(Messages.getString("rowset.12")); //$NON-NLS-1$
+        }
+
+        if (matchColumnNames == null) {
+            /*
+             * FIXME initial match column, the default length of array is 10 in
+             * RI, we don't know why, just follow now
+             */
+            matchColumnNames = new String[10];
+        }
+
+        matchColumnNames[0] = columnName;
     }
 
     public void setMatchColumn(String[] columnNames) throws SQLException {
-        throw new NotImplementedException();
+        if (columnNames == null) {
+            throw new NullPointerException();
+        }
+        for (String name : columnNames) {
+            if (name == null || name.equals("")) { //$NON-NLS-1$
+                // rowset.12=Match columns should not be empty or null string
+                throw new SQLException(Messages.getString("rowset.12")); //$NON-NLS-1$
+            }
+        }
+
+        if (matchColumnNames == null) {
+            /*
+             * FIXME initial match column, the default length of array is 10 in
+             * RI, we don't know why, just follow now
+             */
+            matchColumnNames = new String[10];
+        }
+
+        String[] newValue = new String[matchColumnNames.length
+                + columnNames.length];
+        System.arraycopy(columnNames, 0, newValue, 0, columnNames.length);
+        System.arraycopy(matchColumnNames, 0, newValue, columnNames.length,
+                matchColumnNames.length);
+
+        matchColumnNames = newValue;
     }
 
     public void unsetMatchColumn(int columnIdx) throws SQLException {
-        throw new NotImplementedException();
+
+        if (matchColumnIndexes == null || matchColumnIndexes.length == 0
+                || matchColumnIndexes[0] != columnIdx) {
+            throw new SQLException(Messages.getString("rowset.15")); //$NON-NLS-1$
+        }
+
+        matchColumnIndexes[0] = -1;
     }
 
     public void unsetMatchColumn(int[] columnIdxes) throws SQLException {
-        throw new NotImplementedException();
+        if (columnIdxes == null) {
+            throw new NullPointerException();
+        }
+
+        if (columnIdxes.length == 0) {
+            return;
+        }
+
+        if (matchColumnIndexes == null
+                || matchColumnIndexes.length < columnIdxes.length) {
+            throw new SQLException(Messages.getString("rowset.15")); //$NON-NLS-1$
+        }
+
+        for (int i = 0; i < columnIdxes.length; i++) {
+            if (matchColumnIndexes[i] != columnIdxes[i]) {
+                throw new SQLException(Messages.getString("rowset.15")); //$NON-NLS-1$    
+            }
+        }
+
+        Arrays.fill(matchColumnIndexes, 0, columnIdxes.length, -1);
     }
 
     public void unsetMatchColumn(String columnName) throws SQLException {
-        throw new NotImplementedException();
+        if (matchColumnNames == null || matchColumnNames.length == 0
+                || !matchColumnNames[0].equals(columnName)) {
+            throw new SQLException(Messages.getString("rowset.15")); //$NON-NLS-1$
+        }
+
+        matchColumnNames[0] = null;
+
     }
 
     public void unsetMatchColumn(String[] columnName) throws SQLException {
-        throw new NotImplementedException();
-    }
+        if (columnName == null) {
+            throw new NullPointerException();
+        }
 
+        if (columnName.length == 0) {
+            return;
+        }
+
+        if (matchColumnNames == null
+                || matchColumnNames.length < columnName.length) {
+            throw new SQLException(Messages.getString("rowset.15")); //$NON-NLS-1$
+        }
+
+        for (int i = 0; i < columnName.length; i++) {
+            if (matchColumnNames[i] != columnName[i]) {
+                throw new SQLException(Messages.getString("rowset.15")); //$NON-NLS-1$    
+            }
+        }
+
+        Arrays.fill(matchColumnNames, 0, columnName.length, null);
+    }
 }

Added: harmony/enhanced/classlib/trunk/modules/sql/src/test/java/org/apache/harmony/sql/tests/internal/rowset/JdbcRowSetJoinTest.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/sql/src/test/java/org/apache/harmony/sql/tests/internal/rowset/JdbcRowSetJoinTest.java?rev=642919&view=auto
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/sql/src/test/java/org/apache/harmony/sql/tests/internal/rowset/JdbcRowSetJoinTest.java (added)
+++ harmony/enhanced/classlib/trunk/modules/sql/src/test/java/org/apache/harmony/sql/tests/internal/rowset/JdbcRowSetJoinTest.java Mon Mar 31 01:11:30 2008
@@ -0,0 +1,1241 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+package org.apache.harmony.sql.tests.internal.rowset;
+
+import java.sql.SQLException;
+
+import javax.sql.rowset.JdbcRowSet;
+
+public class JdbcRowSetJoinTest extends CachedRowSetTestCase {
+
+    public void testSetMatchColumn_Name() throws Exception {
+        String name = null;
+        JdbcRowSet noInitalJrs = noInitalJdbcRowSet();
+        JdbcRowSet jrs = newJdbcRowSet();
+        /*
+         * TODO spec: throw SQLException, RI throw NullPointerException, Harmony
+         * follow spec
+         */
+        if (!"true".equals(System.getProperty("Testing Harmony"))) {
+            try {
+                noInitalJrs.setMatchColumn(name);
+                fail("Should throw NullPointerException");
+            } catch (NullPointerException e) {
+                // expected
+            }
+        } else {
+
+            try {
+                noInitalJrs.setMatchColumn(name);
+                fail("Should throw SQLException");
+            } catch (SQLException e) {
+                // expected, Match columns should not be empty or null string
+            }
+        }
+
+        try {
+            noInitalJrs.setMatchColumn("");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Match columns should not be empty or null string
+        }
+
+        noInitalJrs.setMatchColumn("not exist");
+        String[] names = noInitalJrs.getMatchColumnNames();
+        assertNotNull(names);
+        assertEquals(10, names.length);
+        assertEquals("not exist", names[0]);
+        for (int i = 1; i < names.length; i++) {
+            assertNull(names[i]);
+        }
+
+        noInitalJrs.setMatchColumn("id");
+        names = noInitalJrs.getMatchColumnNames();
+        assertNotNull(names);
+        assertEquals(10, names.length);
+        assertEquals("id", names[0]);
+        for (int i = 1; i < names.length; i++) {
+            assertNull(names[i]);
+        }
+
+        noInitalJrs.setMatchColumn(new String[] { "ID", "NAME" });
+
+        names = null;
+
+        try {
+            noInitalJrs.setMatchColumn(names);
+            fail("Should throw NullPointerException");
+        } catch (NullPointerException e) {
+            // expected
+        }
+
+        names = noInitalJrs.getMatchColumnNames();
+        assertNotNull(names);
+        assertEquals(12, names.length);
+        assertEquals("ID", names[0]);
+        assertEquals("NAME", names[1]);
+        assertEquals("id", names[2]);
+
+        for (int i = 3; i < names.length; i++) {
+            assertNull(names[i]);
+        }
+
+        try {
+            noInitalJrs.setMatchColumn(new String[] { "ID", "" });
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Match columns should not be empty or null string
+        }
+
+        try {
+            noInitalJrs.setMatchColumn(new String[] { "ID", null });
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Match columns should not be empty or null string
+        }
+
+        noInitalJrs.setMatchColumn("NAME");
+        names = noInitalJrs.getMatchColumnNames();
+        assertNotNull(names);
+        assertEquals(12, names.length);
+        assertEquals("NAME", names[0]);
+        assertEquals("NAME", names[1]);
+        assertEquals("id", names[2]);
+
+        for (int i = 3; i < names.length; i++) {
+            assertNull(names[i]);
+        }
+
+        if (!"true".equals(System.getProperty("Testing Harmony"))) {
+            try {
+                jrs.setMatchColumn(name);
+                fail("Should throw NullPointerException");
+            } catch (NullPointerException e) {
+                // expected
+            }
+        } else {
+
+            try {
+                jrs.setMatchColumn(name);
+                fail("Should throw SQLException");
+            } catch (SQLException e) {
+                // expected, Match columns should not be empty or null string
+            }
+        }
+
+        try {
+            jrs.setMatchColumn("");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Match columns should not be empty or null string
+        }
+
+        jrs.setMatchColumn("not exist");
+        names = jrs.getMatchColumnNames();
+        assertNotNull(names);
+        assertEquals(10, names.length);
+        assertEquals("not exist", names[0]);
+        for (int i = 1; i < names.length; i++) {
+            assertNull(names[i]);
+        }
+
+        jrs.setMatchColumn("id");
+        names = jrs.getMatchColumnNames();
+        assertNotNull(names);
+        assertEquals(10, names.length);
+        assertEquals("id", names[0]);
+        for (int i = 1; i < names.length; i++) {
+            assertNull(names[i]);
+        }
+
+        jrs.setMatchColumn(new String[] { "ID", "NAME" });
+        names = jrs.getMatchColumnNames();
+        assertNotNull(names);
+        assertEquals(12, names.length);
+        assertEquals("ID", names[0]);
+        assertEquals("NAME", names[1]);
+        assertEquals("id", names[2]);
+
+        for (int i = 3; i < names.length; i++) {
+            assertNull(names[i]);
+        }
+
+        try {
+            jrs.setMatchColumn(new String[] { "ID", "" });
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Match columns should not be empty or null string
+        }
+
+        try {
+            jrs.setMatchColumn(new String[] { "ID", null });
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Match columns should not be empty or null string
+        }
+
+        jrs.setMatchColumn("NAME");
+        names = jrs.getMatchColumnNames();
+        assertNotNull(names);
+        assertEquals(12, names.length);
+        assertEquals("NAME", names[0]);
+        assertEquals("NAME", names[1]);
+        assertEquals("id", names[2]);
+
+        for (int i = 3; i < names.length; i++) {
+            assertNull(names[i]);
+        }
+
+    }
+
+    public void testSetMatchColumn_Index() throws Exception {
+        JdbcRowSet noInitalJrs = noInitalJdbcRowSet();
+        JdbcRowSet jrs = newJdbcRowSet();
+        try {
+            noInitalJrs.setMatchColumn(-2);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Match columns should be greater than 0
+        }
+
+        int[] indexes = null;
+
+        try {
+            noInitalJrs.setMatchColumn(indexes);
+            fail("Should throw NullPointerException");
+        } catch (NullPointerException e) {
+            // expected
+        }
+
+        // TODO 0 is valid index 0f column?
+        noInitalJrs.setMatchColumn(0);
+        indexes = noInitalJrs.getMatchColumnIndexes();
+
+        assertNotNull(indexes);
+        assertEquals(10, indexes.length);
+        for (int i = 0; i < indexes.length; i++) {
+            if (i == 0) {
+                assertEquals(0, indexes[i]);
+            } else {
+                assertEquals(-1, indexes[i]);
+            }
+        }
+
+        noInitalJrs.setMatchColumn(1);
+        indexes = noInitalJrs.getMatchColumnIndexes();
+        assertNotNull(indexes);
+        assertEquals(10, indexes.length);
+        for (int i = 0; i < indexes.length; i++) {
+            if (i == 0) {
+                assertEquals(1, indexes[i]);
+            } else {
+                assertEquals(-1, indexes[i]);
+            }
+        }
+
+        noInitalJrs.setMatchColumn(new int[] { 3, 4, 5 });
+        indexes = noInitalJrs.getMatchColumnIndexes();
+
+        try {
+            noInitalJrs.setMatchColumn(new int[] { 3, -3 });
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Match columns should be greater than 0
+        }
+
+        assertNotNull(indexes);
+        assertEquals(13, indexes.length);
+        assertEquals(3, indexes[0]);
+        assertEquals(4, indexes[1]);
+        assertEquals(5, indexes[2]);
+        assertEquals(1, indexes[3]);
+
+        for (int i = 4; i < indexes.length; i++) {
+            assertEquals(-1, indexes[i]);
+        }
+
+        noInitalJrs.setMatchColumn(6);
+        indexes = noInitalJrs.getMatchColumnIndexes();
+        assertNotNull(indexes);
+        assertEquals(13, indexes.length);
+        assertEquals(6, indexes[0]);
+        assertEquals(4, indexes[1]);
+        assertEquals(5, indexes[2]);
+        assertEquals(1, indexes[3]);
+
+        noInitalJrs.setMatchColumn(new int[] { 7, 8 });
+        indexes = noInitalJrs.getMatchColumnIndexes();
+        assertNotNull(indexes);
+        assertEquals(15, indexes.length);
+        assertEquals(7, indexes[0]);
+        assertEquals(8, indexes[1]);
+        assertEquals(6, indexes[2]);
+        assertEquals(4, indexes[3]);
+        assertEquals(5, indexes[4]);
+        assertEquals(1, indexes[5]);
+
+        for (int i = 6; i < indexes.length; i++) {
+            assertEquals(-1, indexes[i]);
+        }
+
+        noInitalJrs.setMatchColumn(9);
+        indexes = noInitalJrs.getMatchColumnIndexes();
+        assertNotNull(indexes);
+        assertEquals(15, indexes.length);
+        assertEquals(9, indexes[0]);
+        assertEquals(8, indexes[1]);
+        assertEquals(6, indexes[2]);
+        assertEquals(4, indexes[3]);
+        assertEquals(5, indexes[4]);
+        assertEquals(1, indexes[5]);
+
+        for (int i = 6; i < indexes.length; i++) {
+            assertEquals(-1, indexes[i]);
+        }
+
+        try {
+            jrs.setMatchColumn(-2);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Match columns should be greater than 0
+        }
+
+        indexes = null;
+
+        try {
+            jrs.setMatchColumn(indexes);
+            fail("Should throw NullPointerException");
+        } catch (NullPointerException e) {
+            // expected
+        }
+
+        jrs.setMatchColumn(0);
+        indexes = jrs.getMatchColumnIndexes();
+
+        assertNotNull(indexes);
+        assertEquals(10, indexes.length);
+        for (int i = 0; i < indexes.length; i++) {
+            if (i == 0) {
+                assertEquals(0, indexes[i]);
+            } else {
+                assertEquals(-1, indexes[i]);
+            }
+        }
+
+        jrs.setMatchColumn(1);
+        indexes = jrs.getMatchColumnIndexes();
+        assertNotNull(indexes);
+        assertEquals(10, indexes.length);
+        for (int i = 0; i < indexes.length; i++) {
+            if (i == 0) {
+                assertEquals(1, indexes[i]);
+            } else {
+                assertEquals(-1, indexes[i]);
+            }
+        }
+
+        jrs.setMatchColumn(new int[] { 3, 4, 5 });
+        indexes = jrs.getMatchColumnIndexes();
+
+        assertNotNull(indexes);
+        assertEquals(13, indexes.length);
+        assertEquals(3, indexes[0]);
+        assertEquals(4, indexes[1]);
+        assertEquals(5, indexes[2]);
+        assertEquals(1, indexes[3]);
+
+        for (int i = 4; i < indexes.length; i++) {
+            assertEquals(-1, indexes[i]);
+        }
+
+        jrs.setMatchColumn(6);
+        indexes = jrs.getMatchColumnIndexes();
+        assertNotNull(indexes);
+        assertEquals(13, indexes.length);
+        assertEquals(6, indexes[0]);
+        assertEquals(4, indexes[1]);
+        assertEquals(5, indexes[2]);
+        assertEquals(1, indexes[3]);
+
+        for (int i = 4; i < indexes.length; i++) {
+            assertEquals(-1, indexes[i]);
+        }
+
+        jrs.setMatchColumn(new int[] { 7, 8 });
+        indexes = jrs.getMatchColumnIndexes();
+        assertNotNull(indexes);
+        assertEquals(15, indexes.length);
+        assertEquals(7, indexes[0]);
+        assertEquals(8, indexes[1]);
+        assertEquals(6, indexes[2]);
+        assertEquals(4, indexes[3]);
+        assertEquals(5, indexes[4]);
+        assertEquals(1, indexes[5]);
+
+        for (int i = 6; i < indexes.length; i++) {
+            assertEquals(-1, indexes[i]);
+        }
+
+        jrs.setMatchColumn(9);
+        indexes = jrs.getMatchColumnIndexes();
+        assertNotNull(indexes);
+        assertEquals(15, indexes.length);
+        assertEquals(9, indexes[0]);
+        assertEquals(8, indexes[1]);
+        assertEquals(6, indexes[2]);
+        assertEquals(4, indexes[3]);
+        assertEquals(5, indexes[4]);
+        assertEquals(1, indexes[5]);
+
+        for (int i = 6; i < indexes.length; i++) {
+            assertEquals(-1, indexes[i]);
+        }
+
+        // exceed column count
+        jrs.setMatchColumn(100);
+        assertEquals(100, jrs.getMatchColumnIndexes()[0]);
+
+        noInitalJrs = noInitalJdbcRowSet();
+
+        noInitalJrs.setMatchColumn(new int[] { 1, 2, 3 });
+        indexes = noInitalJrs.getMatchColumnIndexes();
+        assertNotNull(indexes);
+        assertEquals(13, indexes.length);
+        assertEquals(1, indexes[0]);
+        assertEquals(2, indexes[1]);
+        assertEquals(3, indexes[2]);
+        for (int i = 3; i < indexes.length; i++) {
+            assertEquals(-1, indexes[i]);
+        }
+
+        noInitalJrs = noInitalJdbcRowSet();
+
+    }
+
+    public void testGetMatchColumn() throws Exception {
+        JdbcRowSet noInitalJrs = noInitalJdbcRowSet();
+        JdbcRowSet jrs = newJdbcRowSet();
+        try {
+            noInitalJrs.getMatchColumnIndexes();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        try {
+            noInitalJrs.getMatchColumnNames();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        // mantains match column indexes and match column names separately
+        noInitalJrs.setMatchColumn(0);
+        int[] indexes = noInitalJrs.getMatchColumnIndexes();
+
+        try {
+            noInitalJrs.getMatchColumnNames();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        noInitalJrs.setMatchColumn("test");
+        String[] names = noInitalJrs.getMatchColumnNames();
+
+        assertNotSame(noInitalJrs.getMatchColumnIndexes(), noInitalJrs
+                .getMatchColumnIndexes());
+        assertNotSame(noInitalJrs.getMatchColumnNames(), noInitalJrs
+                .getMatchColumnNames());
+
+    }
+
+    public void testUnsetMatchColumn_Index_Unpopulate() throws Exception {
+        JdbcRowSet noInitalJrs = noInitalJdbcRowSet();
+        JdbcRowSet jrs = newJdbcRowSet();
+        int[] indexes = null;
+        try {
+            noInitalJrs.unsetMatchColumn(indexes);
+            fail("Should throw NullPointerException");
+        } catch (NullPointerException e) {
+            // expected
+        }
+
+        indexes = new int[0];
+
+        noInitalJrs.unsetMatchColumn(indexes);
+
+        indexes = new int[] { 1, 2, 3 };
+        try {
+            noInitalJrs.unsetMatchColumn(indexes);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        try {
+            noInitalJrs.unsetMatchColumn(-2);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        try {
+            noInitalJrs.unsetMatchColumn(0);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        noInitalJrs.setMatchColumn(1);
+        try {
+            noInitalJrs.unsetMatchColumn(2);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        noInitalJrs.unsetMatchColumn(1);
+
+        try {
+            noInitalJrs.getMatchColumnIndexes();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        noInitalJrs.setMatchColumn(new int[] { 1, 2, 3 });
+
+        try {
+            noInitalJrs.unsetMatchColumn(2);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            noInitalJrs.unsetMatchColumn(3);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        noInitalJrs.unsetMatchColumn(1);
+
+        try {
+            noInitalJrs.getMatchColumnIndexes();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        noInitalJrs.setMatchColumn(4);
+        indexes = noInitalJrs.getMatchColumnIndexes();
+        assertNotNull(indexes);
+        assertEquals(13, indexes.length);
+        assertEquals(4, indexes[0]);
+        assertEquals(2, indexes[1]);
+        assertEquals(3, indexes[2]);
+        for (int i = 3; i < indexes.length; i++) {
+            assertEquals(-1, indexes[i]);
+        }
+
+        try {
+            noInitalJrs.unsetMatchColumn(2);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            noInitalJrs.unsetMatchColumn(3);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        noInitalJrs.setMatchColumn(new int[] { 5, 6 });
+        try {
+            noInitalJrs.unsetMatchColumn(2);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            noInitalJrs.unsetMatchColumn(3);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            noInitalJrs.unsetMatchColumn(4);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            noInitalJrs.unsetMatchColumn(6);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        noInitalJrs.unsetMatchColumn(5);
+
+        try {
+            noInitalJrs.getMatchColumnIndexes();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        noInitalJrs.setMatchColumn(7);
+        indexes = noInitalJrs.getMatchColumnIndexes();
+        assertNotNull(indexes);
+        assertEquals(15, indexes.length);
+        assertEquals(7, indexes[0]);
+        assertEquals(6, indexes[1]);
+        assertEquals(4, indexes[2]);
+        assertEquals(2, indexes[3]);
+        assertEquals(3, indexes[4]);
+
+        for (int i = 6; i < indexes.length; i++) {
+            assertEquals(-1, indexes[i]);
+        }
+
+        noInitalJrs.unsetMatchColumn(new int[] { 7, 6 });
+        try {
+            noInitalJrs.getMatchColumnIndexes();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        noInitalJrs.setMatchColumn(new int[] { 7, 6 });
+        indexes = noInitalJrs.getMatchColumnIndexes();
+
+        assertNotNull(indexes);
+        assertEquals(17, indexes.length);
+        assertEquals(7, indexes[0]);
+        assertEquals(6, indexes[1]);
+        assertEquals(-1, indexes[2]);
+        assertEquals(-1, indexes[3]);
+        assertEquals(4, indexes[4]);
+        assertEquals(2, indexes[5]);
+        assertEquals(3, indexes[6]);
+    }
+
+    public void testUnsetMatchColumn_Index() throws Exception {
+        JdbcRowSet noInitalJrs = noInitalJdbcRowSet();
+        JdbcRowSet jrs = newJdbcRowSet();
+        int[] indexes = null;
+        try {
+            jrs.unsetMatchColumn(indexes);
+            fail("Should throw NullPointerException");
+        } catch (NullPointerException e) {
+            // expected
+        }
+
+        indexes = new int[0];
+
+        jrs.unsetMatchColumn(indexes);
+
+        indexes = new int[] { 1, 2, 3 };
+        try {
+            jrs.unsetMatchColumn(indexes);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        try {
+            jrs.unsetMatchColumn(-2);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        try {
+            jrs.unsetMatchColumn(0);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        jrs.setMatchColumn(1);
+        try {
+            jrs.unsetMatchColumn(2);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        jrs.unsetMatchColumn(1);
+
+        try {
+            indexes = jrs.getMatchColumnIndexes();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        jrs.setMatchColumn(new int[] { 1, 2, 3 });
+
+        try {
+            jrs.unsetMatchColumn(2);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            jrs.unsetMatchColumn(3);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        jrs.unsetMatchColumn(1);
+
+        try {
+            jrs.getMatchColumnIndexes();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        jrs.setMatchColumn(4);
+        indexes = jrs.getMatchColumnIndexes();
+        assertNotNull(indexes);
+        assertEquals(13, indexes.length);
+        assertEquals(4, indexes[0]);
+        assertEquals(2, indexes[1]);
+        assertEquals(3, indexes[2]);
+        for (int i = 3; i < indexes.length; i++) {
+            assertEquals(-1, indexes[i]);
+        }
+
+        try {
+            jrs.unsetMatchColumn(2);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            jrs.unsetMatchColumn(3);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        jrs.setMatchColumn(new int[] { 5, 6 });
+        try {
+            jrs.unsetMatchColumn(2);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            jrs.unsetMatchColumn(3);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            jrs.unsetMatchColumn(4);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            jrs.unsetMatchColumn(6);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        jrs.unsetMatchColumn(5);
+
+        try {
+            jrs.getMatchColumnIndexes();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        jrs.setMatchColumn(7);
+        indexes = jrs.getMatchColumnIndexes();
+        assertNotNull(indexes);
+        assertEquals(15, indexes.length);
+        assertEquals(7, indexes[0]);
+        assertEquals(6, indexes[1]);
+        assertEquals(4, indexes[2]);
+        assertEquals(2, indexes[3]);
+        assertEquals(3, indexes[4]);
+
+        for (int i = 6; i < indexes.length; i++) {
+            assertEquals(-1, indexes[i]);
+        }
+
+        jrs.unsetMatchColumn(new int[] { 7, 6 });
+        try {
+            jrs.getMatchColumnIndexes();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        jrs.setMatchColumn(new int[] { 7, 6 });
+        indexes = jrs.getMatchColumnIndexes();
+
+        assertNotNull(indexes);
+        assertEquals(17, indexes.length);
+        assertEquals(7, indexes[0]);
+        assertEquals(6, indexes[1]);
+        assertEquals(-1, indexes[2]);
+        assertEquals(-1, indexes[3]);
+        assertEquals(4, indexes[4]);
+        assertEquals(2, indexes[5]);
+        assertEquals(3, indexes[6]);
+
+        jrs.unsetMatchColumn(new int[] { 7, 6, -1, -1, 4, 2, 3 });
+        try {
+            indexes = jrs.getMatchColumnIndexes();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+    }
+
+    public void testUnsetMatchColumn_Name_Unpopulate() throws Exception {
+        JdbcRowSet noInitalJrs = noInitalJdbcRowSet();
+        JdbcRowSet jrs = newJdbcRowSet();
+        String[] names = null;
+        try {
+            noInitalJrs.unsetMatchColumn(names);
+            fail("Should throw NullPointerException");
+        } catch (NullPointerException e) {
+            // expected
+        }
+
+        names = new String[0];
+
+        noInitalJrs.unsetMatchColumn(names);
+
+        names = new String[] { "1", "2", "3" };
+        try {
+            noInitalJrs.unsetMatchColumn(names);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        /*
+         * TODO behavior of unsetMatchColumn(String) is not the same with
+         * unsetMatchColumn(int) in RI, we think throw SQLException is more
+         * reasonable
+         */
+        if ("true".equals(System.getProperty("Testing Harmony"))) {
+            try {
+                noInitalJrs.unsetMatchColumn("");
+                fail("Should throw SQLException");
+            } catch (SQLException e) {
+                // expected, Columns being unset are not the same as set
+            }
+            try {
+                noInitalJrs.unsetMatchColumn("0");
+                fail("Should throw SQLException");
+            } catch (SQLException e) {
+                // expected, Columns being unset are not the same as set
+            }
+        } else {
+            try {
+                noInitalJrs.unsetMatchColumn("");
+                fail("Should throw NullPointerException");
+            } catch (NullPointerException e) {
+                // expected
+            }
+
+            try {
+                noInitalJrs.unsetMatchColumn("0");
+                fail("Should throw NullPointerException");
+            } catch (NullPointerException e) {
+                // expected
+            }
+
+        }
+
+        noInitalJrs.setMatchColumn("1");
+        try {
+            noInitalJrs.unsetMatchColumn("2");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        noInitalJrs.unsetMatchColumn("1");
+
+        try {
+            noInitalJrs.getMatchColumnNames();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        noInitalJrs.setMatchColumn(new String[] { "1", "2", "3" });
+
+        try {
+            noInitalJrs.unsetMatchColumn("2");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            noInitalJrs.unsetMatchColumn("3");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        noInitalJrs.unsetMatchColumn("1");
+
+        try {
+            noInitalJrs.getMatchColumnNames();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        noInitalJrs.setMatchColumn("4");
+        names = noInitalJrs.getMatchColumnNames();
+        assertNotNull(names);
+        assertEquals(13, names.length);
+        assertEquals("4", names[0]);
+        assertEquals("2", names[1]);
+        assertEquals("3", names[2]);
+        for (int i = 3; i < names.length; i++) {
+            assertNull(names[i]);
+        }
+
+        try {
+            noInitalJrs.unsetMatchColumn("2");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            noInitalJrs.unsetMatchColumn("3");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        noInitalJrs.setMatchColumn(new String[] { "5", "6" });
+        try {
+            noInitalJrs.unsetMatchColumn("2");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            noInitalJrs.unsetMatchColumn("3");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            noInitalJrs.unsetMatchColumn("4");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            noInitalJrs.unsetMatchColumn("6");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        noInitalJrs.unsetMatchColumn("5");
+
+        try {
+            noInitalJrs.getMatchColumnNames();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        noInitalJrs.setMatchColumn("7");
+        names = noInitalJrs.getMatchColumnNames();
+        assertNotNull(names);
+        assertEquals(15, names.length);
+        assertEquals("7", names[0]);
+        assertEquals("6", names[1]);
+        assertEquals("4", names[2]);
+        assertEquals("2", names[3]);
+        assertEquals("3", names[4]);
+
+        for (int i = 6; i < names.length; i++) {
+            assertNull(names[i]);
+        }
+
+        noInitalJrs.unsetMatchColumn(new String[] { "7", "6" });
+        try {
+            noInitalJrs.getMatchColumnNames();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        noInitalJrs.setMatchColumn(new String[] { "7", "6" });
+        names = noInitalJrs.getMatchColumnNames();
+
+        assertNotNull(names);
+        assertEquals(17, names.length);
+        assertEquals("7", names[0]);
+        assertEquals("6", names[1]);
+        assertNull(names[2]);
+        assertNull(names[3]);
+        assertEquals("4", names[4]);
+        assertEquals("2", names[5]);
+        assertEquals("3", names[6]);
+    }
+
+    public void testUnsetMatchColumn_Name() throws Exception {
+        JdbcRowSet noInitalJrs = noInitalJdbcRowSet();
+        JdbcRowSet jrs = newJdbcRowSet();
+        String[] names = null;
+        try {
+            jrs.unsetMatchColumn(names);
+            fail("Should throw NullPointerException");
+        } catch (NullPointerException e) {
+            // expected
+        }
+
+        names = new String[0];
+
+        jrs.unsetMatchColumn(names);
+
+        names = new String[] { "1", "2", "3" };
+        try {
+            jrs.unsetMatchColumn(names);
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        /*
+         * TODO behavior of unsetMatchColumn(String) is not the same with
+         * unsetMatchColumn(int) in RI, we think throw SQLException is more
+         * reasonable
+         */
+        if ("true".equals(System.getProperty("Testing Harmony"))) {
+            try {
+                jrs.unsetMatchColumn("");
+                fail("Should throw SQLException");
+            } catch (SQLException e) {
+                // expected, Columns being unset are not the same as set
+            }
+            try {
+                jrs.unsetMatchColumn("0");
+                fail("Should throw SQLException");
+            } catch (SQLException e) {
+                // expected, Columns being unset are not the same as set
+            }
+        } else {
+            try {
+                jrs.unsetMatchColumn("");
+                fail("Should throw NullPointerException");
+            } catch (NullPointerException e) {
+                // expected
+            }
+
+            try {
+                jrs.unsetMatchColumn("0");
+                fail("Should throw NullPointerException");
+            } catch (NullPointerException e) {
+                // expected
+            }
+
+        }
+
+        jrs.setMatchColumn("1");
+        try {
+            jrs.unsetMatchColumn("2");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        jrs.unsetMatchColumn("1");
+
+        try {
+            jrs.getMatchColumnNames();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        jrs.setMatchColumn(new String[] { "1", "2", "3" });
+
+        try {
+            jrs.unsetMatchColumn("2");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            jrs.unsetMatchColumn("3");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        jrs.unsetMatchColumn("1");
+
+        try {
+            jrs.getMatchColumnNames();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        jrs.setMatchColumn("4");
+        names = jrs.getMatchColumnNames();
+        assertNotNull(names);
+        assertEquals(13, names.length);
+        assertEquals("4", names[0]);
+        assertEquals("2", names[1]);
+        assertEquals("3", names[2]);
+        for (int i = 3; i < names.length; i++) {
+            assertNull(names[i]);
+        }
+
+        try {
+            jrs.unsetMatchColumn("2");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            jrs.unsetMatchColumn("3");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        jrs.setMatchColumn(new String[] { "5", "6" });
+        try {
+            jrs.unsetMatchColumn("2");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            jrs.unsetMatchColumn("3");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            jrs.unsetMatchColumn("4");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+        try {
+            jrs.unsetMatchColumn("6");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+
+        jrs.unsetMatchColumn("5");
+
+        try {
+            jrs.getMatchColumnNames();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        jrs.setMatchColumn("7");
+        names = jrs.getMatchColumnNames();
+        assertNotNull(names);
+        assertEquals(15, names.length);
+        assertEquals("7", names[0]);
+        assertEquals("6", names[1]);
+        assertEquals("4", names[2]);
+        assertEquals("2", names[3]);
+        assertEquals("3", names[4]);
+
+        for (int i = 6; i < names.length; i++) {
+            assertNull(names[i]);
+        }
+
+        jrs.unsetMatchColumn(new String[] { "7", "6" });
+        try {
+            jrs.getMatchColumnNames();
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Set Match columns before getting them
+        }
+
+        jrs.setMatchColumn(new String[] { "7", "6" });
+        names = jrs.getMatchColumnNames();
+
+        assertNotNull(names);
+        assertEquals(17, names.length);
+        assertEquals("7", names[0]);
+        assertEquals("6", names[1]);
+        assertNull(names[2]);
+        assertNull(names[3]);
+        assertEquals("4", names[4]);
+        assertEquals("2", names[5]);
+        assertEquals("3", names[6]);
+
+        jrs = noInitalJdbcRowSet();
+
+        // test whether column name is case sensitive
+        jrs.setMatchColumn("TesT");
+        assertEquals("TesT", jrs.getMatchColumnNames()[0]);
+        try {
+            jrs.unsetMatchColumn("test");
+            fail("Should throw SQLException");
+        } catch (SQLException e) {
+            // expected, Columns being unset are not the same as set
+        }
+    }
+
+    protected JdbcRowSet noInitalJdbcRowSet() throws Exception {
+        try {
+            return (JdbcRowSet) Class.forName("com.sun.rowset.JdbcRowSetImpl")
+                    .newInstance();
+        } catch (ClassNotFoundException e) {
+            return (JdbcRowSet) Class.forName(
+                    "org.apache.harmony.sql.internal.rowset.JdbcRowSetImpl")
+                    .newInstance();
+        }
+    }
+
+    protected JdbcRowSet newJdbcRowSet() throws Exception {
+        JdbcRowSet noInitalJrs = noInitalJdbcRowSet();
+        noInitalJrs.setUrl(DERBY_URL);
+        noInitalJrs.setCommand("SELECT * FROM USER_INFO");
+        noInitalJrs.execute();
+        return noInitalJrs;
+    }
+
+}

Propchange: harmony/enhanced/classlib/trunk/modules/sql/src/test/java/org/apache/harmony/sql/tests/internal/rowset/JdbcRowSetJoinTest.java
------------------------------------------------------------------------------
    svn:eol-style = native



Mime
View raw message