teiid SVN: r3093 - in trunk/engine/src: test/java/org/teiid/query/optimizer and 1 other directory.
by teiid-commits@lists.jboss.org
Author: shawkins
Date: 2011-04-15 09:59:42 -0400 (Fri, 15 Apr 2011)
New Revision: 3093
Modified:
trunk/engine/src/main/java/org/teiid/query/optimizer/relational/rules/RulePlanSorts.java
trunk/engine/src/test/java/org/teiid/query/optimizer/TestSortOptimization.java
Log:
TEIID-1554 fix for npe with order by project optimization
Modified: trunk/engine/src/main/java/org/teiid/query/optimizer/relational/rules/RulePlanSorts.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/query/optimizer/relational/rules/RulePlanSorts.java 2011-04-15 01:56:17 UTC (rev 3092)
+++ trunk/engine/src/main/java/org/teiid/query/optimizer/relational/rules/RulePlanSorts.java 2011-04-15 13:59:42 UTC (rev 3093)
@@ -272,9 +272,17 @@
}
if (raiseAccess) {
PlanNode accessNode = node.getFirstChild();
- root = RuleRaiseAccess.raiseAccessNode(root, accessNode, metadata, capFinder, true, record);
- if (accessNode.getParent().getType() == NodeConstants.Types.TUPLE_LIMIT) {
- root = RulePushLimit.raiseAccessOverLimit(root, accessNode, metadata, capFinder, accessNode.getParent());
+ //instead of just calling ruleraiseaccess, we're more selective
+ //we do not want to raise the access node over a project that is handling an unrelated sort
+ PlanNode newRoot = RuleRaiseAccess.raiseAccessNode(root, accessNode, metadata, capFinder, true, record);
+ if (newRoot != null) {
+ root = newRoot;
+ if (accessNode.getParent().getType() == NodeConstants.Types.TUPLE_LIMIT) {
+ newRoot = RulePushLimit.raiseAccessOverLimit(root, accessNode, metadata, capFinder, accessNode.getParent());
+ }
+ if (newRoot != null) {
+ root = newRoot;
+ }
}
}
return root;
Modified: trunk/engine/src/test/java/org/teiid/query/optimizer/TestSortOptimization.java
===================================================================
--- trunk/engine/src/test/java/org/teiid/query/optimizer/TestSortOptimization.java 2011-04-15 01:56:17 UTC (rev 3092)
+++ trunk/engine/src/test/java/org/teiid/query/optimizer/TestSortOptimization.java 2011-04-15 13:59:42 UTC (rev 3093)
@@ -204,6 +204,14 @@
new String[] {"SELECT g_0.e1 AS c_0, g_0.e2 AS c_1 FROM pm1.g1 AS g_0 ORDER BY c_0"}, ComparisonMode.EXACT_COMMAND_STRING); //$NON-NLS-1$
}
+ @Test public void testProjectionRaisingWithAccessAndLimit() throws Exception {
+ // Create query
+ String sql = "select e1, (select e1 from pm2.g1 where e2 = x.e2) as z from pm1.g1 as x order by e1 limit 1"; //$NON-NLS-1$
+
+ helpPlan(sql, FakeMetadataFactory.example1Cached(), null, TestOptimizer.getGenericFinder(),
+ new String[] {"SELECT g_0.e1 AS c_0, g_0.e2 AS c_1 FROM pm1.g1 AS g_0 ORDER BY c_0"}, ComparisonMode.EXACT_COMMAND_STRING); //$NON-NLS-1$
+ }
+
@Test public void testProjectionRaisingForUnrelatedWithLimit() throws Exception {
FakeCapabilitiesFinder capFinder = new FakeCapabilitiesFinder();
BasicSourceCapabilities caps = new BasicSourceCapabilities();
13 years, 8 months
teiid SVN: r3092 - in trunk/common-core/src: test/java/org/teiid/core/types and 1 other directory.
by teiid-commits@lists.jboss.org
Author: shawkins
Date: 2011-04-14 21:56:17 -0400 (Thu, 14 Apr 2011)
New Revision: 3092
Modified:
trunk/common-core/src/main/java/org/teiid/core/types/DataTypeManager.java
trunk/common-core/src/test/java/org/teiid/core/types/TestDataTypeManager.java
Log:
TEIID-1538 adding the catch all object to string conversion
Modified: trunk/common-core/src/main/java/org/teiid/core/types/DataTypeManager.java
===================================================================
--- trunk/common-core/src/main/java/org/teiid/core/types/DataTypeManager.java 2011-04-15 01:43:34 UTC (rev 3091)
+++ trunk/common-core/src/main/java/org/teiid/core/types/DataTypeManager.java 2011-04-15 01:56:17 UTC (rev 3092)
@@ -691,6 +691,13 @@
DataTypeManager.addTransform(new NullToAnyTransform(type));
}
}
+
+ DataTypeManager.addTransform(new AnyToStringTransform(DefaultDataClasses.OBJECT) {
+ @Override
+ public boolean isExplicit() {
+ return true;
+ }
+ });
}
Modified: trunk/common-core/src/test/java/org/teiid/core/types/TestDataTypeManager.java
===================================================================
--- trunk/common-core/src/test/java/org/teiid/core/types/TestDataTypeManager.java 2011-04-15 01:43:34 UTC (rev 3091)
+++ trunk/common-core/src/test/java/org/teiid/core/types/TestDataTypeManager.java 2011-04-15 01:56:17 UTC (rev 3092)
@@ -32,6 +32,7 @@
import org.junit.Test;
+@SuppressWarnings("nls")
public class TestDataTypeManager {
private void helpDetermineDataType(Object value, Class<?> expectedClass) {
@@ -206,9 +207,19 @@
DataTypeManager.DefaultDataTypes.OBJECT), DataTypeManager.getImplicitConversions(DataTypeManager.DefaultDataTypes.INTEGER));
}
- @SuppressWarnings("unchecked")
@Test(expected=TransformationException.class) public void testStringToXML() throws Exception {
DataTypeManager.transformValue("hello", DataTypeManager.DefaultDataClasses.XML); //$NON-NLS-1$
}
+ static class Foo {
+ @Override
+ public String toString() {
+ return "hello";
+ }
+ }
+
+ @Test public void testObjectToString() throws Exception {
+ assertEquals("hello", DataTypeManager.transformValue(new Foo(), DataTypeManager.DefaultDataClasses.STRING)); //$NON-NLS-1$
+ }
+
}
13 years, 8 months
teiid SVN: r3091 - in trunk: test-integration/common/src/test/java/org/teiid/transport and 2 other directories.
by teiid-commits@lists.jboss.org
Author: shawkins
Date: 2011-04-14 21:43:34 -0400 (Thu, 14 Apr 2011)
New Revision: 3091
Added:
trunk/test-integration/common/src/test/java/org/teiid/transport/TestJDBCSocketTransport.java
trunk/test-integration/common/src/test/resources/TestJDBCSocketTransport/
trunk/test-integration/common/src/test/resources/TestJDBCSocketTransport/testSelect.expected
Modified:
trunk/client/src/main/java/org/teiid/jdbc/StatementImpl.java
Log:
TEIID-1536 fixing the regression with synch query execution
Modified: trunk/client/src/main/java/org/teiid/jdbc/StatementImpl.java
===================================================================
--- trunk/client/src/main/java/org/teiid/jdbc/StatementImpl.java 2011-04-14 16:19:52 UTC (rev 3090)
+++ trunk/client/src/main/java/org/teiid/jdbc/StatementImpl.java 2011-04-15 01:43:34 UTC (rev 3091)
@@ -526,16 +526,32 @@
final RequestMessage reqMessage = createRequestMessage(commands, isBatchedCommand, resultsMode);
reqMessage.setSync(synch);
- ResultsFuture<Boolean> result = execute(reqMessage);
+ ResultsFuture<ResultsMessage> pendingResult = execute(reqMessage, synch);
+ final ResultsFuture<Boolean> result = new ResultsFuture<Boolean>();
+ pendingResult.addCompletionListener(new ResultsFuture.CompletionListener<ResultsMessage>() {
+ @Override
+ public void onCompletion(ResultsFuture<ResultsMessage> future) {
+ try {
+ postReceiveResults(reqMessage, future.get());
+ result.getResultsReceiver().receiveResults(hasResultSet());
+ } catch (Throwable t) {
+ result.getResultsReceiver().exceptionOccurred(t);
+ }
+ }
+ });
if (synch) {
try {
if (queryTimeoutMS > 0) {
- result.get(queryTimeoutMS, TimeUnit.MILLISECONDS);
+ pendingResult.get(queryTimeoutMS, TimeUnit.MILLISECONDS);
} else {
- result.get();
+ pendingResult.get();
}
+ result.get(); //throw an exception if needed
return result;
} catch (ExecutionException e) {
+ if (e.getCause() instanceof SQLException) {
+ throw (SQLException)e.getCause();
+ }
throw TeiidSQLException.create(e);
} catch (InterruptedException e) {
timeoutOccurred();
@@ -547,7 +563,7 @@
return result;
}
- private ResultsFuture<Boolean> execute(final RequestMessage reqMsg) throws SQLException,
+ private ResultsFuture<ResultsMessage> execute(final RequestMessage reqMsg, boolean synch) throws SQLException,
TeiidSQLException {
this.getConnection().beginLocalTxnIfNeeded();
this.currentRequestID = this.driverConnection.nextRequestID();
@@ -564,7 +580,7 @@
reqMsg.setExecutionId(this.currentRequestID);
ResultsFuture.CompletionListener<ResultsMessage> compeletionListener = null;
- if (queryTimeoutMS > 0) {
+ if (queryTimeoutMS > 0 && !synch) {
final CancelTask c = new QueryTimeoutCancelTask(queryTimeoutMS, this);
cancellationTimer.add(c);
compeletionListener = new ResultsFuture.CompletionListener<ResultsMessage>() {
@@ -584,19 +600,7 @@
if (compeletionListener != null) {
pendingResult.addCompletionListener(compeletionListener);
}
- final ResultsFuture<Boolean> result = new ResultsFuture<Boolean>();
- pendingResult.addCompletionListener(new ResultsFuture.CompletionListener<ResultsMessage>() {
- @Override
- public void onCompletion(ResultsFuture<ResultsMessage> future) {
- try {
- postReceiveResults(reqMsg, future.get());
- result.getResultsReceiver().receiveResults(hasResultSet());
- } catch (Throwable t) {
- result.getResultsReceiver().exceptionOccurred(t);
- }
- }
- });
- return result;
+ return pendingResult;
}
public static ResultsFuture<Boolean> booleanFuture(boolean isTrue) {
Added: trunk/test-integration/common/src/test/java/org/teiid/transport/TestJDBCSocketTransport.java
===================================================================
--- trunk/test-integration/common/src/test/java/org/teiid/transport/TestJDBCSocketTransport.java (rev 0)
+++ trunk/test-integration/common/src/test/java/org/teiid/transport/TestJDBCSocketTransport.java 2011-04-15 01:43:34 UTC (rev 3091)
@@ -0,0 +1,93 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * See the COPYRIGHT.txt file distributed with this work for information
+ * regarding copyright ownership. Some portions may be licensed
+ * to Red Hat, Inc. under one or more contributor license agreements.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA.
+ */
+
+package org.teiid.transport;
+
+import static org.junit.Assert.*;
+
+import java.net.InetSocketAddress;
+import java.sql.Connection;
+import java.sql.Statement;
+import java.util.Properties;
+
+import org.junit.After;
+import org.junit.AfterClass;
+import org.junit.Before;
+import org.junit.BeforeClass;
+import org.junit.Test;
+import org.teiid.common.buffer.BufferManagerFactory;
+import org.teiid.core.util.UnitTestUtil;
+import org.teiid.jdbc.FakeServer;
+import org.teiid.jdbc.TeiidDriver;
+import org.teiid.jdbc.TestMMDatabaseMetaData;
+
+@SuppressWarnings("nls")
+public class TestJDBCSocketTransport {
+
+ static InetSocketAddress addr;
+ static SocketListener jdbcTransport;
+
+ @BeforeClass public static void oneTimeSetup() throws Exception {
+ SocketConfiguration config = new SocketConfiguration();
+ config.setSSLConfiguration(new SSLConfiguration());
+ addr = new InetSocketAddress(0);
+ config.setBindAddress(addr.getHostName());
+ config.setPortNumber(0);
+
+ FakeServer server = new FakeServer();
+ server.setUseCallingThread(false);
+ server.deployVDB("parts", UnitTestUtil.getTestDataPath() + "/PartsSupplier.vdb");
+
+ jdbcTransport = new SocketListener(config, server, BufferManagerFactory.getStandaloneBufferManager(), 0);
+ }
+
+ @AfterClass public static void oneTimeTearDown() throws Exception {
+ if (jdbcTransport != null) {
+ jdbcTransport.stop();
+ }
+ }
+
+ Connection conn;
+
+ @Before public void setUp() throws Exception {
+ Properties p = new Properties();
+ p.setProperty("user", "testuser");
+ p.setProperty("password", "testpassword");
+ conn = TeiidDriver.getInstance().connect("jdbc:teiid:parts@mm://"+addr.getHostName()+":" +jdbcTransport.getPort(), p);
+ }
+
+ @After public void tearDown() throws Exception {
+ if (conn != null) {
+ conn.close();
+ }
+ }
+
+ /**
+ * Under the covers this still executes a prepared statement due to the driver handling
+ */
+ @Test public void testSelect() throws Exception {
+ Statement s = conn.createStatement();
+ assertTrue(s.execute("select * from tables order by name"));
+ TestMMDatabaseMetaData.compareResultSet(s.getResultSet());
+ }
+
+}
Property changes on: trunk/test-integration/common/src/test/java/org/teiid/transport/TestJDBCSocketTransport.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/test-integration/common/src/test/resources/TestJDBCSocketTransport/testSelect.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestJDBCSocketTransport/testSelect.expected (rev 0)
+++ trunk/test-integration/common/src/test/resources/TestJDBCSocketTransport/testSelect.expected 2011-04-15 01:43:34 UTC (rev 3091)
@@ -0,0 +1,48 @@
+string string string string string boolean boolean string integer string boolean boolean integer
+VDBName SchemaName Name Type NameInSource IsPhysical SupportsUpdates UID Cardinality Description IsSystem IsMaterialized OID
+parts SYS Columns Table <null> true false mmuuid:1c9a5cb2-17b1-4e4a-8b0e-3a42bd052509 0 <null> true false 8
+parts SYS DataTypes Table <null> true false mmuuid:9a8794f9-66f8-49e8-8576-89d212d0f957 0 <null> true false 9
+parts SYS KeyColumns Table <null> true false mmuuid:14946083-3bd5-42d5-8283-1c0694347c29 0 <null> true false 10
+parts SYS Keys Table <null> true false mmuuid:1e5135dc-ce5d-4b25-a8ff-63f5440b3108 0 <null> true false 11
+parts SYSADMIN MatViews Table <null> true false mmuuid:520ba1e8-3553-460f-8d18-9b43f089e256 0 <null> true false 6
+parts PartsSupplier PARTSSUPPLIER.PARTS Table PARTS true true mmuuid:f6276601-73fe-1edc-a81c-ecf397b10590 16 <null> false false 1
+parts PartsSupplier PARTSSUPPLIER.SHIP_VIA Table SHIP_VIA true true mmuuid:0f4e9b80-73ff-1edc-a81c-ecf397b10590 4 <null> false false 2
+parts PartsSupplier PARTSSUPPLIER.STATUS Table STATUS true true mmuuid:1f297200-73ff-1edc-a81c-ecf397b10590 3 <null> false false 3
+parts PartsSupplier PARTSSUPPLIER.SUPPLIER Table SUPPLIER true true mmuuid:2c371ec0-73ff-1edc-a81c-ecf397b10590 16 <null> false false 5
+parts PartsSupplier PARTSSUPPLIER.SUPPLIER_PARTS Table SUPPLIER_PARTS true true mmuuid:3deafb00-73ff-1edc-a81c-ecf397b10590 227 <null> false false 4
+parts SYS ProcedureParams Table <null> true false mmuuid:a56bd7fe-c87a-411c-8f5d-661975a25626 0 <null> true false 12
+parts SYS Procedures Table <null> true false mmuuid:0bc132a5-9f8d-4a3c-9f5d-98156a98a962 0 <null> true false 13
+parts SYS Properties Table <null> true false mmuuid:7a45e50a-d03f-4548-ba35-761651bbca85 0 <null> true false 14
+parts SYS ReferenceKeyColumns Table <null> true false mmuuid:6a9653e8-a337-41b2-86fa-77b98f409a29 0 <null> true false 15
+parts SYS Schemas Table <null> true false mmuuid:8648a554-b2ad-4e8e-84ca-2ec618b311a9 0 <null> true false 16
+parts SYS Tables Table <null> true false mmuuid:8551b3bd-11cc-4049-9bcf-fe91a0eb7ba7 0 <null> true false 17
+parts SYSADMIN VDBResources Table <null> true false mmuuid:1785804d-beaf-4831-9531-e59164fedd49 0 <null> true false 7
+parts SYS VirtualDatabases Table <null> true false mmuuid:47297c72-d621-4f4e-af4e-74060ac5f489 0 <null> true false 18
+parts pg_catalog matpg_datatype Table <null> false false mmuid:17448311-6679-4dfd-aeb6-4aabbd894729 0 <null> true true 31
+parts pg_catalog matpg_relatt Table <null> false false mmuid:8c0714d6-1c72-40b4-8528-3b2c63059107 0 <null> true true 30
+parts pg_catalog pg_am Table <null> false false mmuid:f6517a63-8c14-4b73-a18d-afaa5dfb35d9 0 <null> true false 24
+parts pg_catalog pg_attrdef Table <null> false false mmuid:76a7dd05-9a7d-4243-b561-f3056500dcaf 0 <null> true false 27
+parts pg_catalog pg_attribute Table <null> false false mmuid:fa463d98-365f-489a-a707-025193cb51eb 0 <null> true true 21
+parts pg_catalog pg_class Table <null> false false mmuid:7e21f2e6-06e3-4bca-9b01-72ea47821560 0 <null> true true 20
+parts pg_catalog pg_database Table <null> false false mmuid:382f9fc9-8c96-4df7-ab5d-04dfb47ee142 0 <null> true false 28
+parts pg_catalog pg_index Table <null> false false mmuid:09daed8d-b0b8-4552-a261-2b6c775b46b0 0 <null> true true 23
+parts pg_catalog pg_namespace Table <null> false false mmuid:6609866a-3d7b-4f4b-95fe-ebfac769d699 0 <null> true false 19
+parts pg_catalog pg_proc Table <null> false false mmuid:f20c9489-10ca-4596-8a37-24218b67f764 0 <null> true true 25
+parts pg_catalog pg_trigger Table <null> false false mmuid:2b75f0b1-7475-4ed5-9da3-d37a8a25f26a 0 <null> true false 26
+parts pg_catalog pg_type Table <null> false false mmuid:9462e3f8-cd3c-414f-a570-f6f33c40e36a 0 <null> true false 22
+parts pg_catalog pg_user Table <null> false false mmuid:e63613cb-01ee-4b37-8b91-99d1aac4dfcb 0 <null> true false 29
+Row Count : 31
+getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
+VDBName 12 parts java.lang.String VDBName string SYS Tables 255 255 0 false true false true 1 false true true true
+SchemaName 12 parts java.lang.String SchemaName string SYS Tables 255 255 0 false true false true 1 false true true true
+Name 12 parts java.lang.String Name string SYS Tables 255 255 0 false true false false 0 true true false false
+Type 12 parts java.lang.String Type string SYS Tables 20 20 0 false false false false 0 true true false false
+NameInSource 12 parts java.lang.String NameInSource string SYS Tables 255 255 0 false true false false 1 true true false false
+IsPhysical -7 parts java.lang.Boolean IsPhysical boolean SYS Tables 5 1 0 false true false false 0 true true false false
+SupportsUpdates -7 parts java.lang.Boolean SupportsUpdates boolean SYS Tables 5 1 0 false false false false 0 true true false false
+UID 12 parts java.lang.String UID string SYS Tables 50 50 0 false false false false 0 true true false false
+Cardinality 4 parts java.lang.Integer Cardinality integer SYS Tables 11 10 0 false true false false 0 true true true false
+Description 12 parts java.lang.String Description string SYS Tables 255 255 0 false true false true 1 false true true true
+IsSystem -7 parts java.lang.Boolean IsSystem boolean SYS Tables 5 1 0 false true false true 1 false true true true
+IsMaterialized -7 parts java.lang.Boolean IsMaterialized boolean SYS Tables 5 1 0 false false false true 0 false true false true
+OID 4 parts java.lang.Integer OID integer SYS Tables 11 10 0 false false false false 0 true true false false
13 years, 8 months
teiid SVN: r3090 - in trunk/engine/src/main/java/org/teiid: query/function/aggregate and 1 other directories.
by teiid-commits@lists.jboss.org
Author: shawkins
Date: 2011-04-14 12:19:52 -0400 (Thu, 14 Apr 2011)
New Revision: 3090
Modified:
trunk/engine/src/main/java/org/teiid/common/buffer/FileStore.java
trunk/engine/src/main/java/org/teiid/common/buffer/FileStoreInputStreamFactory.java
trunk/engine/src/main/java/org/teiid/query/function/aggregate/TextAgg.java
trunk/engine/src/main/java/org/teiid/query/function/aggregate/XMLAgg.java
trunk/engine/src/main/java/org/teiid/query/function/source/XMLSystemFunctions.java
Log:
TEIID-1556 better handling for xmlagg and reducing the memory held by associated buffers
Modified: trunk/engine/src/main/java/org/teiid/common/buffer/FileStore.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/common/buffer/FileStore.java 2011-04-13 20:34:39 UTC (rev 3089)
+++ trunk/engine/src/main/java/org/teiid/common/buffer/FileStore.java 2011-04-14 16:19:52 UTC (rev 3090)
@@ -27,6 +27,7 @@
import java.io.OutputStream;
import java.lang.ref.PhantomReference;
import java.lang.ref.ReferenceQueue;
+import java.util.Arrays;
import java.util.Collections;
import java.util.IdentityHashMap;
import java.util.Set;
@@ -46,6 +47,7 @@
private byte[] buffer;
private int count;
private boolean bytesWritten;
+ private boolean closed;
public FileStoreOutputStream(int size) {
this.buffer = new byte[size];
@@ -58,6 +60,7 @@
@Override
public void write(byte[] b, int off, int len) throws IOException {
+ checkOpen();
if (len > buffer.length) {
flushBuffer();
writeDirect(b, off, len);
@@ -86,12 +89,18 @@
}
public void flushBuffer() throws IOException {
+ checkOpen();
if (count > 0) {
writeDirect(buffer, 0, count);
count = 0;
}
}
+ /**
+ * Return the buffer. Can be null if closed and the underlying filestore
+ * has been writen to.
+ * @return
+ */
public byte[] getBuffer() {
return buffer;
}
@@ -114,8 +123,21 @@
@Override
public void close() throws IOException {
flush();
+ closed = true;
+ if (bytesWritten) {
+ this.buffer = null;
+ } else {
+ //truncate
+ this.buffer = Arrays.copyOf(this.buffer, this.count);
+ }
}
+ private void checkOpen() {
+ if (closed) {
+ throw new IllegalStateException("Alread closed"); //$NON-NLS-1$
+ }
+ }
+
}
static class CleanupReference extends PhantomReference<Object> {
Modified: trunk/engine/src/main/java/org/teiid/common/buffer/FileStoreInputStreamFactory.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/common/buffer/FileStoreInputStreamFactory.java 2011-04-13 20:34:39 UTC (rev 3089)
+++ trunk/engine/src/main/java/org/teiid/common/buffer/FileStoreInputStreamFactory.java 2011-04-14 16:19:52 UTC (rev 3090)
@@ -59,10 +59,20 @@
return lobBuffer.getLength();
}
+ /**
+ * Returns a new writer instance that is backed by the shared output stream.
+ * Closing a writer will prevent further writes.
+ * @return
+ */
public Writer getWriter() {
return new OutputStreamWriter(getOuputStream(), Charset.forName(encoding));
}
+ /**
+ * The returned output stream is shared among all uses.
+ * Once closed no further writing can occur
+ * @return
+ */
public FileStoreOutputStream getOuputStream() {
if (fsos == null) {
fsos = lobBuffer.createOutputStream(DataTypeManager.MAX_LOB_MEMORY_BYTES);
@@ -77,6 +87,6 @@
@Override
public boolean isPersistent() {
- return true;
+ return fsos == null || fsos.bytesWritten();
}
}
\ No newline at end of file
Modified: trunk/engine/src/main/java/org/teiid/query/function/aggregate/TextAgg.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/query/function/aggregate/TextAgg.java 2011-04-13 20:34:39 UTC (rev 3089)
+++ trunk/engine/src/main/java/org/teiid/query/function/aggregate/TextAgg.java 2011-04-14 16:19:52 UTC (rev 3090)
@@ -72,7 +72,7 @@
}
}, textLine.getDelimiter(), textLine.getQuote()));
}
- w.close();
+ w.flush();
return fisf;
} catch (IOException e) {
throw new TeiidProcessingException(e);
@@ -96,7 +96,7 @@
String in = (String)input;
Writer w = result.getWriter();
w.write(in);
- w.close();
+ w.flush();
} catch (IOException e) {
throw new TeiidProcessingException(e);
}
Modified: trunk/engine/src/main/java/org/teiid/query/function/aggregate/XMLAgg.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/query/function/aggregate/XMLAgg.java 2011-04-13 20:34:39 UTC (rev 3089)
+++ trunk/engine/src/main/java/org/teiid/query/function/aggregate/XMLAgg.java 2011-04-14 16:19:52 UTC (rev 3090)
@@ -27,7 +27,7 @@
import org.teiid.core.TeiidComponentException;
import org.teiid.core.TeiidProcessingException;
import org.teiid.core.types.XMLType;
-import org.teiid.query.function.source.XMLSystemFunctions;
+import org.teiid.query.function.source.XMLSystemFunctions.XmlConcat;
import org.teiid.query.util.CommandContext;
/**
@@ -35,7 +35,8 @@
*/
public class XMLAgg extends AggregateFunction {
- private XMLType result;
+ private XMLType result;
+ private XmlConcat concat;
private CommandContext context;
public XMLAgg(CommandContext context) {
@@ -43,7 +44,8 @@
}
public void reset() {
- result = null;
+ concat = null;
+ result = null;
}
/**
@@ -52,13 +54,25 @@
* @see org.teiid.query.function.aggregate.AggregateFunction#addInputDirect(Object, List)
*/
public void addInputDirect(Object input, List<?> tuple) throws TeiidComponentException, TeiidProcessingException {
- result = XMLSystemFunctions.xmlConcat(context, result, input);
+ if (concat == null) {
+ concat = new XmlConcat(context.getBufferManager());
+ }
+ concat.addValue(input);
}
/**
+ * @throws TeiidProcessingException
+ * @throws TeiidComponentException
* @see org.teiid.query.function.aggregate.AggregateFunction#getResult()
*/
- public Object getResult() {
+ public Object getResult() throws TeiidComponentException, TeiidProcessingException {
+ if (result == null) {
+ if (concat == null) {
+ return null;
+ }
+ result = concat.close();
+ concat = null;
+ }
return result;
}
Modified: trunk/engine/src/main/java/org/teiid/query/function/source/XMLSystemFunctions.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/query/function/source/XMLSystemFunctions.java 2011-04-13 20:34:39 UTC (rev 3089)
+++ trunk/engine/src/main/java/org/teiid/query/function/source/XMLSystemFunctions.java 2011-04-14 16:19:52 UTC (rev 3090)
@@ -386,27 +386,67 @@
return singleValue;
}
- XMLType result = new XMLType(XMLSystemFunctions.saveToBufferManager(context.getBufferManager(), new XMLTranslator() {
-
- @Override
- public void translate(Writer writer) throws TransformerException,
- IOException {
- try {
- XMLOutputFactory factory = getOutputFactory();
- XMLEventWriter eventWriter = factory.createXMLEventWriter(writer);
- XMLEventFactory eventFactory = XMLEventFactory.newInstance();
- convertValue(writer, eventWriter, eventFactory, xml);
- for (Object object : other) {
- convertValue(writer, eventWriter, eventFactory, object);
- }
- eventWriter.flush(); //woodstox needs a flush rather than a close
- } catch (XMLStreamException e) {
- throw new TransformerException(e);
- }
+ XmlConcat concat = new XmlConcat(context.getBufferManager());
+ concat.addValue(xml);
+ for (Object object : other) {
+ concat.addValue(object);
+ }
+ return concat.close();
+ }
+
+ public static class XmlConcat {
+ private XMLOutputFactory factory;
+ private XMLEventWriter eventWriter;
+ private XMLEventFactory eventFactory;
+ private Writer writer;
+ private FileStoreInputStreamFactory fsisf;
+ private FileStore fs;
+
+ public XmlConcat(BufferManager bm) throws TeiidProcessingException {
+ fs = bm.createFileStore("xml"); //$NON-NLS-1$
+ fsisf = new FileStoreInputStreamFactory(fs, Streamable.ENCODING);
+ writer = fsisf.getWriter();
+ factory = getOutputFactory();
+ try {
+ eventWriter = factory.createXMLEventWriter(writer);
+ } catch (XMLStreamException e) {
+ fs.remove();
+ throw new TeiidProcessingException(e);
}
- }));
- result.setType(Type.CONTENT);
- return result;
+ eventFactory = XMLEventFactory.newInstance();
+ }
+
+ public void addValue(Object object) throws TeiidProcessingException {
+ try {
+ convertValue(writer, eventWriter, eventFactory, object);
+ } catch (IOException e) {
+ fs.remove();
+ throw new TeiidProcessingException(e);
+ } catch (XMLStreamException e) {
+ fs.remove();
+ throw new TeiidProcessingException(e);
+ } catch (TransformerException e) {
+ fs.remove();
+ throw new TeiidProcessingException(e);
+ }
+ }
+
+ public XMLType close() throws TeiidProcessingException {
+ try {
+ eventWriter.flush();
+ writer.close();
+ } catch (XMLStreamException e) {
+ fs.remove();
+ throw new TeiidProcessingException(e);
+ } catch (IOException e) {
+ fs.remove();
+ throw new TeiidProcessingException(e);
+ }
+ XMLType result = new XMLType(new SQLXMLImpl(fsisf));
+ result.setType(Type.CONTENT);
+ return result;
+ }
+
}
private static XMLOutputFactory getOutputFactory() throws FactoryConfigurationError {
13 years, 8 months
teiid SVN: r3089 - in trunk: api/src/main/java/org/teiid/events and 15 other directories.
by teiid-commits@lists.jboss.org
Author: shawkins
Date: 2011-04-13 16:34:39 -0400 (Wed, 13 Apr 2011)
New Revision: 3089
Added:
trunk/api/src/main/java/org/teiid/events/
Removed:
trunk/engine/src/main/java/org/teiid/events/
Modified:
trunk/api/src/main/java/org/teiid/events/EventDistributor.java
trunk/cache-jbosscache/pom.xml
trunk/console/src/main/resources/META-INF/rhq-plugin.xml
trunk/engine/src/main/java/org/teiid/dqp/internal/process/AccessInfo.java
trunk/engine/src/main/java/org/teiid/dqp/internal/process/DQPConfiguration.java
trunk/engine/src/main/java/org/teiid/dqp/internal/process/DQPCore.java
trunk/engine/src/main/java/org/teiid/dqp/internal/process/DataTierManagerImpl.java
trunk/engine/src/main/java/org/teiid/dqp/internal/process/DataTierTupleSource.java
trunk/engine/src/main/java/org/teiid/query/function/aggregate/ArrayAgg.java
trunk/engine/src/main/java/org/teiid/query/metadata/TempMetadataID.java
trunk/engine/src/main/java/org/teiid/query/metadata/TransformationMetadata.java
trunk/engine/src/main/java/org/teiid/query/processor/ProcessorDataManager.java
trunk/engine/src/main/java/org/teiid/query/sql/lang/BatchedUpdateCommand.java
trunk/engine/src/main/java/org/teiid/query/tempdata/TempTable.java
trunk/engine/src/main/java/org/teiid/query/tempdata/TempTableDataManager.java
trunk/engine/src/test/java/org/teiid/dqp/internal/process/TestDQPCore.java
trunk/engine/src/test/java/org/teiid/dqp/internal/process/TestDataTierManager.java
trunk/engine/src/test/java/org/teiid/dqp/service/AutoGenDataService.java
trunk/engine/src/test/java/org/teiid/query/processor/FakeDataManager.java
trunk/engine/src/test/java/org/teiid/query/processor/HardcodedDataManager.java
trunk/engine/src/test/java/org/teiid/query/processor/relational/TestBatchedUpdateNode.java
trunk/engine/src/test/java/org/teiid/query/processor/relational/TestProjectIntoNode.java
trunk/jboss-integration/src/main/java/org/teiid/jboss/deployers/RuntimeEngineDeployer.java
trunk/test-integration/common/src/test/java/org/teiid/dqp/internal/process/TestXMLTypeTranslations.java
Log:
TEIID-1507 refining previous check-in and adding detection of local data change events
Modified: trunk/api/src/main/java/org/teiid/events/EventDistributor.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/events/EventDistributor.java 2011-04-12 23:20:51 UTC (rev 3084)
+++ trunk/api/src/main/java/org/teiid/events/EventDistributor.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -24,8 +24,41 @@
import java.util.List;
+/**
+ * Distributes events across the Teiid cluster
+ */
public interface EventDistributor {
+
+ /**
+ * Update the given materialized view row using the internal mat view name #MAT_VIEWFQN.
+ * The tuple is expected to be in table order, which has the primary key first.
+ * Deletes need to only send the key, not the entire row contents.
+ *
+ * @param vdbName
+ * @param vdbVersion
+ * @param matViewFqn
+ * @param tuple
+ * @param delete
+ */
void updateMatViewRow(String vdbName, int vdbVersion, String matViewFqn, List<?> tuple, boolean delete);
- void schemaModification(String vdbName, int vdbVersion, String fqn);
- void dataModification(String vdbName, int vdbVersion, String tableFqn);
+
+ /**
+ * Notify that the metadata has been changed for the given fqns.
+ * A fqn has the form schema.entityname.
+ * This typically implies that the costing metadata has changed, but may also indicate
+ * a view definition has changed.
+ * @param vdbName
+ * @param vdbVersion
+ * @param fqns
+ */
+ void schemaModification(String vdbName, int vdbVersion, String... fqns);
+
+ /**
+ * Notify that the table data has changed.
+ * A table fqn has the form schema.tablename.
+ * @param vdbName
+ * @param vdbVersion
+ * @param tableFqns
+ */
+ void dataModification(String vdbName, int vdbVersion, String... tableFqns);
}
Modified: trunk/cache-jbosscache/pom.xml
===================================================================
--- trunk/cache-jbosscache/pom.xml 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/cache-jbosscache/pom.xml 2011-04-13 20:34:39 UTC (rev 3089)
@@ -14,7 +14,12 @@
<groupId>org.jboss.teiid</groupId>
<artifactId>teiid-common-core</artifactId>
<scope>provided</scope>
- </dependency>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.teiid</groupId>
+ <artifactId>teiid-api</artifactId>
+ <scope>provided</scope>
+ </dependency>
<dependency>
<groupId>org.jboss.teiid</groupId>
<artifactId>teiid-engine</artifactId>
Modified: trunk/console/src/main/resources/META-INF/rhq-plugin.xml
===================================================================
--- trunk/console/src/main/resources/META-INF/rhq-plugin.xml 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/console/src/main/resources/META-INF/rhq-plugin.xml 2011-04-13 20:34:39 UTC (rev 3089)
@@ -330,7 +330,11 @@
<c:simple-property name="RuntimeEngineDeployer.useDataRoles"
displayName="Data Roles Enabled"
description="Turn on role checking of resources based on the roles defined in VDB (default true)"
- required="false" readOnly="false" />
+ required="false" readOnly="false" />
+ <c:simple-property name="RuntimeEngineDeployer.detectingChangeEvents"
+ displayName="Detecting Change Events"
+ description="Set to true for the engine to detect local change events. Should be disabled if using external change data capture tools. (default true)"
+ required="false" readOnly="false" />
</c:group>
<c:group name="ResultSetCacheConfig" displayName="ResultSet Cache Properties" hiddenByDefault="false">
Modified: trunk/engine/src/main/java/org/teiid/dqp/internal/process/AccessInfo.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/dqp/internal/process/AccessInfo.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/main/java/org/teiid/dqp/internal/process/AccessInfo.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -171,7 +171,7 @@
}
} else if (o instanceof TempMetadataID) {
TempMetadataID tid = (TempMetadataID)o;
- if (tid.getTableData().getLastModified() - modTime > this.creationTime) {
+ if ((data?tid.getTableData().getLastDataModification():tid.getTableData().getLastModified()) - modTime > this.creationTime) {
return false;
}
}
Modified: trunk/engine/src/main/java/org/teiid/dqp/internal/process/DQPConfiguration.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/dqp/internal/process/DQPConfiguration.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/main/java/org/teiid/dqp/internal/process/DQPConfiguration.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -55,6 +55,7 @@
private CacheConfiguration preparedPlanCacheConfig = new CacheConfiguration();
private int maxODBCLobSizeAllowed = 5*1024*1024; // 5 MB
private int userRequestSourceConcurrency = DEFAULT_USER_REQUEST_SOURCE_CONCURRENCY;
+ private boolean detectingChangeEvents = true;
private transient AuthorizationValidator authorizationValidator;
private transient MetadataProvider metadataProvider;
@@ -231,4 +232,13 @@
this.preparedPlanCacheConfig = preparedPlanCacheConfig;
}
+ public boolean isDetectingChangeEvents() {
+ return detectingChangeEvents;
+ }
+
+ @ManagementProperty(description="Set to true for the engine to detect local change events. Should be disabled if using external change data capture tools. (default true)")
+ public void setDetectingChangeEvents(boolean detectingChangeEvents) {
+ this.detectingChangeEvents = detectingChangeEvents;
+ }
+
}
Modified: trunk/engine/src/main/java/org/teiid/dqp/internal/process/DQPCore.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/dqp/internal/process/DQPCore.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/main/java/org/teiid/dqp/internal/process/DQPCore.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -715,7 +715,7 @@
matTables.setBufferManager(this.bufferManager);
}
- dataTierMgr = new TempTableDataManager(new DataTierManagerImpl(this,this.bufferService), this.bufferManager, this.processWorkerPool, this.rsCache, this.matTables, this.cacheFactory);
+ dataTierMgr = new TempTableDataManager(new DataTierManagerImpl(this,this.bufferService, this.config.isDetectingChangeEvents()), this.bufferManager, this.processWorkerPool, this.rsCache, this.matTables, this.cacheFactory);
}
public void setBufferService(BufferService service) {
Modified: trunk/engine/src/main/java/org/teiid/dqp/internal/process/DataTierManagerImpl.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/dqp/internal/process/DataTierManagerImpl.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/main/java/org/teiid/dqp/internal/process/DataTierManagerImpl.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -52,6 +52,7 @@
import org.teiid.dqp.message.AtomicRequestMessage;
import org.teiid.dqp.message.RequestID;
import org.teiid.dqp.service.BufferService;
+import org.teiid.events.EventDistributor;
import org.teiid.metadata.AbstractMetadataRecord;
import org.teiid.metadata.Column;
import org.teiid.metadata.Datatype;
@@ -110,12 +111,27 @@
// Resources
private DQPCore requestMgr;
private BufferService bufferService;
+ private EventDistributor eventDistributor;
+ private boolean detectChangeEvents;
- public DataTierManagerImpl(DQPCore requestMgr, BufferService bufferService) {
+ public DataTierManagerImpl(DQPCore requestMgr, BufferService bufferService, boolean detectChangeEvents) {
this.requestMgr = requestMgr;
this.bufferService = bufferService;
+ this.detectChangeEvents = detectChangeEvents;
}
+ public boolean detectChangeEvents() {
+ return detectChangeEvents;
+ }
+
+ public void setEventDistributor(EventDistributor eventDistributor) {
+ this.eventDistributor = eventDistributor;
+ }
+
+ public EventDistributor getEventDistributor() {
+ return eventDistributor;
+ }
+
public TupleSource registerRequest(CommandContext context, Command command, String modelName, String connectorBindingId, int nodeID, int limit) throws TeiidComponentException, TeiidProcessingException {
RequestWorkItem workItem = requestMgr.getRequestWorkItem((RequestID)context.getProcessorID());
Modified: trunk/engine/src/main/java/org/teiid/dqp/internal/process/DataTierTupleSource.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/dqp/internal/process/DataTierTupleSource.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/main/java/org/teiid/dqp/internal/process/DataTierTupleSource.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -23,6 +23,7 @@
package org.teiid.dqp.internal.process;
import java.io.IOException;
+import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.concurrent.Callable;
@@ -56,7 +57,13 @@
import org.teiid.dqp.internal.process.DQPCore.FutureWork;
import org.teiid.dqp.message.AtomicRequestMessage;
import org.teiid.dqp.message.AtomicResultsMessage;
+import org.teiid.metadata.Table;
import org.teiid.query.function.source.XMLSystemFunctions;
+import org.teiid.query.processor.relational.RelationalNodeUtil;
+import org.teiid.query.sql.lang.BatchedUpdateCommand;
+import org.teiid.query.sql.lang.Command;
+import org.teiid.query.sql.lang.ProcedureContainer;
+import org.teiid.query.sql.symbol.GroupSymbol;
import org.teiid.query.sql.symbol.SingleElementSymbol;
import org.teiid.translator.DataNotAvailableException;
import org.teiid.translator.TranslatorException;
@@ -133,7 +140,7 @@
}, this, 100);
}
- private List correctTypes(List row) throws TransformationException {
+ private List<?> correctTypes(List<Object> row) throws TransformationException {
//TODO: add a proper intermediate schema
for (int i = 0; i < row.size(); i++) {
Object value = row.get(i);
@@ -213,6 +220,25 @@
} else {
results = getResults();
}
+ //check for update events
+ if (index == 0 && this.dtm.detectChangeEvents()) {
+ Command command = aqr.getCommand();
+ ArrayList<String> updates = new ArrayList<String>();
+ int commandIndex = 0;
+ if (RelationalNodeUtil.isUpdate(command)) {
+ long ts = System.currentTimeMillis();
+ checkForUpdates(results, command, updates, commandIndex, ts);
+ } else if (command instanceof BatchedUpdateCommand) {
+ long ts = System.currentTimeMillis();
+ BatchedUpdateCommand bac = (BatchedUpdateCommand)command;
+ for (Command uc : bac.getUpdateCommands()) {
+ checkForUpdates(results, uc, updates, commandIndex++, ts);
+ }
+ }
+ if (this.dtm.getEventDistributor() != null && !updates.isEmpty()) {
+ this.dtm.getEventDistributor().dataModification(this.workItem.getDqpWorkContext().getVdbName(), this.workItem.getDqpWorkContext().getVdbVersion(), updates.toArray(new String[updates.size()]));
+ }
+ }
} catch (TranslatorException e) {
results = exceptionOccurred(e, true);
} catch (DataNotAvailableException e) {
@@ -241,6 +267,29 @@
}
}
+ private void checkForUpdates(AtomicResultsMessage results, Command command,
+ ArrayList<String> updates, int commandIndex, long ts) {
+ if (!RelationalNodeUtil.isUpdate(command) || !(command instanceof ProcedureContainer)) {
+ return;
+ }
+ ProcedureContainer pc = (ProcedureContainer)aqr.getCommand();
+ GroupSymbol gs = pc.getGroup();
+ Integer zero = Integer.valueOf(0);
+ if (results.getResults().length <= commandIndex || zero.equals(results.getResults()[commandIndex].get(0))) {
+ return;
+ }
+ Object metadataId = gs.getMetadataID();
+ if (metadataId == null) {
+ return;
+ }
+ if (!(metadataId instanceof Table)) {
+ return;
+ }
+ Table t = (Table)metadataId;
+ updates.add(t.getFullName());
+ t.setLastDataModification(ts);
+ }
+
private AtomicResultsMessage asynchGet()
throws BlockedException, TeiidProcessingException,
TeiidComponentException, TranslatorException {
Modified: trunk/engine/src/main/java/org/teiid/query/function/aggregate/ArrayAgg.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/query/function/aggregate/ArrayAgg.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/main/java/org/teiid/query/function/aggregate/ArrayAgg.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -45,6 +45,9 @@
this.result = new ArrayList<Object>();
}
this.result.add(input);
+ if (this.result.size() > 1000) {
+ throw new AssertionError("Exceeded the max allowable array size of 1000."); //$NON-NLS-1$
+ }
}
@Override
Modified: trunk/engine/src/main/java/org/teiid/query/metadata/TempMetadataID.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/query/metadata/TempMetadataID.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/main/java/org/teiid/query/metadata/TempMetadataID.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -33,7 +33,6 @@
import org.teiid.query.sql.lang.CacheHint;
import org.teiid.query.sql.symbol.SingleElementSymbol;
-
/**
* This class represents a temporary metadata ID. A temporary metadata ID
* does not exist in a real metadata source. Rather, it is used temporarily
@@ -48,6 +47,8 @@
private static final long serialVersionUID = -1879211827339120135L;
private static final int LOCAL_CACHE_SIZE = 8;
+ private static final int MOD_COUNT_FOR_COST_UPDATE = 8;
+
public static class TableData {
Collection<TempMetadataID> accessPatterns;
List<TempMetadataID> elements;
@@ -58,15 +59,31 @@
CacheHint cacheHint;
List<List<TempMetadataID>> keys;
List<List<TempMetadataID>> indexes;
+ long lastDataModification;
long lastModified;
+ int modCount;
+ public long getLastDataModification() {
+ return lastDataModification;
+ }
+
+ public void dataModified(int updateCount) {
+ if (updateCount == 0) {
+ return;
+ }
+ long ts = System.currentTimeMillis();
+ modCount += updateCount;
+ if (modCount > MOD_COUNT_FOR_COST_UPDATE) {
+ this.lastModified = ts;
+ modCount = 0;
+ }
+ this.lastDataModification = ts;
+ }
+
public long getLastModified() {
return lastModified;
}
- public void setLastModified(long lastModified) {
- this.lastModified = lastModified;
- }
}
private static TableData DUMMY_DATA = new TableData();
Modified: trunk/engine/src/main/java/org/teiid/query/metadata/TransformationMetadata.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/query/metadata/TransformationMetadata.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/main/java/org/teiid/query/metadata/TransformationMetadata.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -262,9 +262,9 @@
public boolean hasProcedure(String name) throws TeiidComponentException {
try {
- return getStoredProcedureInfoForProcedure(name) != null;
+ return getStoredProcInfoDirect(name) != null;
} catch (QueryMetadataException e) {
- return false;
+ return true;
}
}
Modified: trunk/engine/src/main/java/org/teiid/query/processor/ProcessorDataManager.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/query/processor/ProcessorDataManager.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/main/java/org/teiid/query/processor/ProcessorDataManager.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -26,6 +26,7 @@
import org.teiid.common.buffer.TupleSource;
import org.teiid.core.TeiidComponentException;
import org.teiid.core.TeiidProcessingException;
+import org.teiid.events.EventDistributor;
import org.teiid.query.sql.lang.Command;
import org.teiid.query.util.CommandContext;
@@ -47,5 +48,7 @@
String keyElementName,
Object keyValue) throws BlockedException,
TeiidComponentException, TeiidProcessingException;
+
+ void setEventDistributor(EventDistributor ed);
}
Modified: trunk/engine/src/main/java/org/teiid/query/sql/lang/BatchedUpdateCommand.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/query/sql/lang/BatchedUpdateCommand.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/main/java/org/teiid/query/sql/lang/BatchedUpdateCommand.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -23,10 +23,9 @@
package org.teiid.query.sql.lang;
import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
import java.util.List;
+import org.teiid.query.sql.LanguageObject;
import org.teiid.query.sql.LanguageVisitor;
import org.teiid.query.sql.util.VariableContext;
@@ -38,42 +37,13 @@
*/
public class BatchedUpdateCommand extends Command {
- protected List commands;
+ protected List<Command> commands;
private List<VariableContext> variableContexts; //processing state
- /**
- * Add sub command
- * @param command Additional sub-command
- */
- public void addSubCommand(Command command) {
- if(this.commands == null) {
- this.commands = new ArrayList();
- }
- this.commands.add(command);
- }
-
- /**
- * Add sub commands
- * @param commands Additional sub-commands
- */
- public void addSubCommands(Collection commands) {
- if(commands == null || commands.size() == 0) {
- return;
- }
-
- if(this.commands == null) {
- this.commands = new ArrayList();
- }
- this.commands.addAll(commands);
- }
-
/**
* @see org.teiid.query.sql.lang.Command#getSubCommands()
*/
- public List getSubCommands() {
- if(commands == null || commands.size() == 0) {
- return Collections.EMPTY_LIST;
- }
+ public List<Command> getSubCommands() {
return commands;
}
@@ -82,8 +52,8 @@
* @param updateCommands
* @since 4.2
*/
- public BatchedUpdateCommand(List updateCommands) {
- addSubCommands(updateCommands);
+ public BatchedUpdateCommand(List<? extends Command> updateCommands) {
+ this.commands = new ArrayList<Command>(updateCommands);
}
/**
@@ -91,7 +61,7 @@
* @return
* @since 4.2
*/
- public List getUpdateCommands() {
+ public List<Command> getUpdateCommands() {
return getSubCommands();
}
@@ -123,10 +93,7 @@
* @since 4.2
*/
public Object clone() {
- List clonedCommands = new ArrayList(commands.size());
- for (int i = 0; i < commands.size(); i++) {
- clonedCommands.add(((Command)commands.get(i)).clone());
- }
+ List<Command> clonedCommands = LanguageObject.Util.deepClone(this.commands, Command.class);
BatchedUpdateCommand copy = new BatchedUpdateCommand(clonedCommands);
copyMetadataState(copy);
return copy;
@@ -142,9 +109,9 @@
public String toString() {
StringBuffer val = new StringBuffer("BatchedUpdate{"); //$NON-NLS-1$
if (commands != null && commands.size() > 0) {
- val.append(getCommandToken((Command)commands.get(0)));
+ val.append(getCommandToken(commands.get(0)));
for (int i = 1; i < commands.size(); i++) {
- val.append(',').append(getCommandToken((Command)commands.get(i)));
+ val.append(',').append(getCommandToken(commands.get(i)));
}
}
val.append('}');
Modified: trunk/engine/src/main/java/org/teiid/query/tempdata/TempTable.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/query/tempdata/TempTable.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/main/java/org/teiid/query/tempdata/TempTable.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -482,7 +482,7 @@
}
public int truncate() {
- this.tid.getTableData().setLastModified(System.currentTimeMillis());
+ this.tid.getTableData().dataModified(tree.getRowCount());
return tree.truncate();
}
@@ -513,7 +513,7 @@
UpdateProcessor up = new InsertUpdateProcessor(tuples, rowId != null, shouldProject?indexes:null);
int updateCount = up.process();
tid.setCardinality(tree.getRowCount());
- tid.getTableData().setLastModified(System.currentTimeMillis());
+ tid.getTableData().dataModified(updateCount);
return CollectionTupleSource.createUpdateCountTupleSource(updateCount);
}
@@ -579,9 +579,7 @@
};
int updateCount = up.process();
- if (updateCount > 0) {
- tid.getTableData().setLastModified(System.currentTimeMillis());
- }
+ tid.getTableData().dataModified(updateCount);
return CollectionTupleSource.createUpdateCountTupleSource(updateCount);
}
@@ -614,9 +612,7 @@
};
int updateCount = up.process();
tid.setCardinality(tree.getRowCount());
- if (updateCount > 0) {
- tid.getTableData().setLastModified(System.currentTimeMillis());
- }
+ tid.getTableData().dataModified(updateCount);
return CollectionTupleSource.createUpdateCountTupleSource(updateCount);
}
@@ -646,7 +642,7 @@
index.tree.remove(tuple);
}
}
- tid.getTableData().setLastModified(System.currentTimeMillis());
+ tid.getTableData().dataModified(1);
return result;
}
List<?> result = tree.insert(tuple, InsertMode.UPDATE, -1);
@@ -656,7 +652,7 @@
index.tree.insert(tuple, InsertMode.UPDATE, -1);
}
}
- tid.getTableData().setLastModified(System.currentTimeMillis());
+ tid.getTableData().dataModified(1);
return result;
} finally {
lock.writeLock().unlock();
Modified: trunk/engine/src/main/java/org/teiid/query/tempdata/TempTableDataManager.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/query/tempdata/TempTableDataManager.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/main/java/org/teiid/query/tempdata/TempTableDataManager.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -161,6 +161,7 @@
public void setEventDistributor(EventDistributor eventDistributor) {
this.eventDistributor = eventDistributor;
+ this.processorDataManager.setEventDistributor(eventDistributor);
}
public TupleSource registerRequest(
Modified: trunk/engine/src/test/java/org/teiid/dqp/internal/process/TestDQPCore.java
===================================================================
--- trunk/engine/src/test/java/org/teiid/dqp/internal/process/TestDQPCore.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/test/java/org/teiid/dqp/internal/process/TestDQPCore.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -37,6 +37,7 @@
import org.mockito.Mockito;
import org.teiid.CommandContext;
import org.teiid.api.exception.query.QueryResolverException;
+import org.teiid.cache.CacheConfiguration;
import org.teiid.cache.DefaultCacheFactory;
import org.teiid.client.RequestMessage;
import org.teiid.client.ResultsMessage;
@@ -87,8 +88,10 @@
config = new DQPConfiguration();
config.setMaxActivePlans(1);
config.setUserRequestSourceConcurrency(2);
+ config.setResultsetCacheConfig(new CacheConfiguration());
core.start(config);
core.getPrepPlanCache().setModTime(1);
+ core.getRsCache().setModTime(1);
}
@After public void tearDown() throws Exception {
@@ -376,6 +379,21 @@
Thread.sleep(100);
+ //perform a minor update, we should still use the cache
+ sql = "delete from #temp where a12345 = '11'"; //$NON-NLS-1$
+ reqMsg = exampleRequestMessage(sql);
+ rm = execute(userName, sessionid, reqMsg);
+ assertEquals(1, rm.getResults().length); //$NON-NLS-1$
+
+ sql = "select * from #temp"; //$NON-NLS-1$
+ reqMsg = exampleRequestMessage(sql);
+ reqMsg.setStatementType(StatementType.PREPARED);
+ rm = execute(userName, sessionid, reqMsg);
+ assertEquals(10, rm.getResults().length); //$NON-NLS-1$
+
+ assertEquals(2, this.core.getPrepPlanCache().getCacheHitCount());
+
+ //perform a minor update, we will purge the plan
sql = "delete from #temp"; //$NON-NLS-1$
reqMsg = exampleRequestMessage(sql);
rm = execute(userName, sessionid, reqMsg);
@@ -387,9 +405,42 @@
rm = execute(userName, sessionid, reqMsg);
assertEquals(0, rm.getResults().length); //$NON-NLS-1$
- assertEquals(1, this.core.getPrepPlanCache().getCacheHitCount());
+ assertEquals(2, this.core.getPrepPlanCache().getCacheHitCount());
}
+ @Test public void testRsCacheInvalidation() throws Exception {
+ String sql = "select * FROM vqt.SmallB"; //$NON-NLS-1$
+ String userName = "1"; //$NON-NLS-1$
+ int sessionid = 1; //$NON-NLS-1$
+ RequestMessage reqMsg = exampleRequestMessage(sql);
+ reqMsg.setUseResultSetCache(true);
+ ResultsMessage rm = execute(userName, sessionid, reqMsg);
+ assertEquals(10, rm.getResults().length); //$NON-NLS-1$
+
+ sql = "select * FROM vqt.SmallB"; //$NON-NLS-1$
+ reqMsg = exampleRequestMessage(sql);
+ reqMsg.setUseResultSetCache(true);
+ rm = execute(userName, sessionid, reqMsg);
+ assertEquals(10, rm.getResults().length); //$NON-NLS-1$
+
+ assertEquals(1, this.core.getRsCache().getCacheHitCount());
+
+ Thread.sleep(100);
+
+ sql = "delete from bqt1.smalla"; //$NON-NLS-1$
+ reqMsg = exampleRequestMessage(sql);
+ rm = execute(userName, sessionid, reqMsg);
+ assertEquals(1, rm.getResults().length); //$NON-NLS-1$
+
+ sql = "select * FROM vqt.SmallB"; //$NON-NLS-1$
+ reqMsg = exampleRequestMessage(sql);
+ reqMsg.setUseResultSetCache(true);
+ rm = execute(userName, sessionid, reqMsg);
+ assertEquals(10, rm.getResults().length); //$NON-NLS-1$
+
+ assertEquals(1, this.core.getRsCache().getCacheHitCount());
+ }
+
public void helpTestVisibilityFails(String sql) throws Exception {
RequestMessage reqMsg = exampleRequestMessage(sql);
reqMsg.setTxnAutoWrapMode(RequestMessage.TXN_WRAP_OFF);
Modified: trunk/engine/src/test/java/org/teiid/dqp/internal/process/TestDataTierManager.java
===================================================================
--- trunk/engine/src/test/java/org/teiid/dqp/internal/process/TestDataTierManager.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/test/java/org/teiid/dqp/internal/process/TestDataTierManager.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -87,7 +87,7 @@
dtm = new DataTierManagerImpl(rm,
- bs);
+ bs, true);
command = helpGetCommand(sql, metadata);
RequestMessage original = new RequestMessage();
Modified: trunk/engine/src/test/java/org/teiid/dqp/service/AutoGenDataService.java
===================================================================
--- trunk/engine/src/test/java/org/teiid/dqp/service/AutoGenDataService.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/test/java/org/teiid/dqp/service/AutoGenDataService.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -25,6 +25,7 @@
import java.math.BigDecimal;
import java.math.BigInteger;
import java.util.ArrayList;
+import java.util.Arrays;
import java.util.Iterator;
import java.util.List;
import java.util.concurrent.atomic.AtomicInteger;
@@ -38,6 +39,7 @@
import org.teiid.dqp.message.AtomicResultsMessage;
import org.teiid.query.optimizer.TestOptimizer;
import org.teiid.query.optimizer.capabilities.SourceCapabilities;
+import org.teiid.query.processor.relational.RelationalNodeUtil;
import org.teiid.query.sql.symbol.SingleElementSymbol;
import org.teiid.translator.DataNotAvailableException;
import org.teiid.translator.TranslatorException;
@@ -83,8 +85,11 @@
@Override
public ConnectorWork registerRequest(AtomicRequestMessage message)
throws TeiidComponentException {
- List projectedSymbols = (message.getCommand()).getProjectedSymbols();
+ List projectedSymbols = (message.getCommand()).getProjectedSymbols();
List[] results = createResults(projectedSymbols);
+ if (RelationalNodeUtil.isUpdate(message.getCommand())) {
+ results = new List[] {Arrays.asList(1)};
+ }
final AtomicResultsMessage msg = ConnectorWorkItem.createResultsMessage(results, projectedSymbols);
msg.setFinalRow(rows);
Modified: trunk/engine/src/test/java/org/teiid/query/processor/FakeDataManager.java
===================================================================
--- trunk/engine/src/test/java/org/teiid/query/processor/FakeDataManager.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/test/java/org/teiid/query/processor/FakeDataManager.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -34,6 +34,7 @@
import org.teiid.common.buffer.BlockedException;
import org.teiid.common.buffer.TupleSource;
import org.teiid.core.TeiidComponentException;
+import org.teiid.events.EventDistributor;
import org.teiid.logging.LogManager;
import org.teiid.query.eval.Evaluator;
import org.teiid.query.metadata.QueryMetadataInterface;
@@ -388,5 +389,8 @@
this.registerTuples(group.getMetadataID(), elementSymbols, tuples);
}
+ @Override
+ public void setEventDistributor(EventDistributor ed) {
+ }
}
\ No newline at end of file
Modified: trunk/engine/src/test/java/org/teiid/query/processor/HardcodedDataManager.java
===================================================================
--- trunk/engine/src/test/java/org/teiid/query/processor/HardcodedDataManager.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/test/java/org/teiid/query/processor/HardcodedDataManager.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -32,6 +32,7 @@
import org.teiid.common.buffer.TupleSource;
import org.teiid.core.TeiidComponentException;
import org.teiid.dqp.internal.datamgr.LanguageBridgeFactory;
+import org.teiid.events.EventDistributor;
import org.teiid.query.metadata.QueryMetadataInterface;
import org.teiid.query.sql.lang.Command;
import org.teiid.query.util.CommandContext;
@@ -167,5 +168,9 @@
public void clearCodeTables() {
}
+
+ @Override
+ public void setEventDistributor(EventDistributor ed) {
+ }
}
Modified: trunk/engine/src/test/java/org/teiid/query/processor/relational/TestBatchedUpdateNode.java
===================================================================
--- trunk/engine/src/test/java/org/teiid/query/processor/relational/TestBatchedUpdateNode.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/test/java/org/teiid/query/processor/relational/TestBatchedUpdateNode.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -36,6 +36,7 @@
import org.teiid.common.buffer.TupleBatch;
import org.teiid.common.buffer.TupleSource;
import org.teiid.core.TeiidComponentException;
+import org.teiid.events.EventDistributor;
import org.teiid.query.metadata.QueryMetadataInterface;
import org.teiid.query.optimizer.TestBatchedUpdatePlanner;
import org.teiid.query.processor.ProcessorDataManager;
@@ -219,6 +220,10 @@
actualCommands.add(command);
return new FakeTupleSource(numExecutedCommands);
}
+ @Override
+ public void setEventDistributor(EventDistributor ed) {
+ }
+
}
private static final class FakeTupleSource implements TupleSource {
private int currentTuple = 0;
Modified: trunk/engine/src/test/java/org/teiid/query/processor/relational/TestProjectIntoNode.java
===================================================================
--- trunk/engine/src/test/java/org/teiid/query/processor/relational/TestProjectIntoNode.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/engine/src/test/java/org/teiid/query/processor/relational/TestProjectIntoNode.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -36,6 +36,7 @@
import org.teiid.common.buffer.TupleSource;
import org.teiid.core.TeiidComponentException;
import org.teiid.core.TeiidProcessingException;
+import org.teiid.events.EventDistributor;
import org.teiid.query.eval.Evaluator;
import org.teiid.query.processor.FakeTupleSource;
import org.teiid.query.processor.ProcessorDataManager;
@@ -184,6 +185,9 @@
Object val = row.get(0);
assertEquals(new Integer(value), val);
}
+ @Override
+ public void setEventDistributor(EventDistributor ed) {
+ }
}
private static final class FakeDataTupleSource implements TupleSource {
Modified: trunk/jboss-integration/src/main/java/org/teiid/jboss/deployers/RuntimeEngineDeployer.java
===================================================================
--- trunk/jboss-integration/src/main/java/org/teiid/jboss/deployers/RuntimeEngineDeployer.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/jboss-integration/src/main/java/org/teiid/jboss/deployers/RuntimeEngineDeployer.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -659,7 +659,7 @@
}
@Override
- public void dataModification(String vdbName, int vdbVersion, String tableFqn) {
+ public void dataModification(String vdbName, int vdbVersion, String... tableFqns) {
VDBMetaData vdb = this.vdbRepository.getVDB(vdbName, vdbVersion);
if (vdb == null) {
return;
@@ -668,16 +668,18 @@
if (tm == null) {
return;
}
- try {
- Table table = tm.getGroupID(tableFqn);
- table.setLastDataModification(System.currentTimeMillis());
- } catch (TeiidException e) {
- LogManager.logError(LogConstants.CTX_DQP, e, QueryPlugin.Util.getString("DQPCore.unable_to_process_event")); //$NON-NLS-1$
+ for (String tableFqn:tableFqns) {
+ try {
+ Table table = tm.getGroupID(tableFqn);
+ table.setLastDataModification(System.currentTimeMillis());
+ } catch (TeiidException e) {
+ LogManager.logError(LogConstants.CTX_DQP, e, QueryPlugin.Util.getString("DQPCore.unable_to_process_event")); //$NON-NLS-1$
+ }
}
}
@Override
- public void schemaModification(String vdbName, int vdbVersion, String fqn) {
+ public void schemaModification(String vdbName, int vdbVersion, String... fqns) {
VDBMetaData vdb = this.vdbRepository.getVDB(vdbName, vdbVersion);
if (vdb == null) {
return;
@@ -686,11 +688,13 @@
if (tm == null) {
return;
}
- try {
- Table table = tm.getGroupID(fqn);
- table.setLastModified(System.currentTimeMillis());
- } catch (TeiidException e) {
- LogManager.logError(LogConstants.CTX_DQP, e, QueryPlugin.Util.getString("DQPCore.unable_to_process_event")); //$NON-NLS-1$
+ for (String fqn:fqns) {
+ try {
+ Table table = tm.getGroupID(fqn);
+ table.setLastModified(System.currentTimeMillis());
+ } catch (TeiidException e) {
+ LogManager.logError(LogConstants.CTX_DQP, e, QueryPlugin.Util.getString("DQPCore.unable_to_process_event")); //$NON-NLS-1$
+ }
}
}
}
Modified: trunk/test-integration/common/src/test/java/org/teiid/dqp/internal/process/TestXMLTypeTranslations.java
===================================================================
--- trunk/test-integration/common/src/test/java/org/teiid/dqp/internal/process/TestXMLTypeTranslations.java 2011-04-13 18:47:33 UTC (rev 3088)
+++ trunk/test-integration/common/src/test/java/org/teiid/dqp/internal/process/TestXMLTypeTranslations.java 2011-04-13 20:34:39 UTC (rev 3089)
@@ -113,7 +113,7 @@
Mockito.stub(rwi.getDqpWorkContext()).toReturn(workContext);
Mockito.stub(core.getRequestWorkItem((RequestID)Mockito.anyObject())).toReturn(rwi);
- DataTierManagerImpl dataMgr = new DataTierManagerImpl(core, null);
+ DataTierManagerImpl dataMgr = new DataTierManagerImpl(core, null, true);
doProcess(metadata,
sql,
finder, dataMgr , new List[] {Arrays.asList(new String(ObjectConverterUtil.convertToByteArray(new FileInputStream(UnitTestUtil.getTestDataFile("test-schema.xsd")))))}, DEBUG); //$NON-NLS-1$
13 years, 8 months
teiid SVN: r3088 - trunk/client/src/main/java.
by teiid-commits@lists.jboss.org
Author: rareddy
Date: 2011-04-13 14:47:33 -0400 (Wed, 13 Apr 2011)
New Revision: 3088
Removed:
trunk/client/src/main/java/net/
Log:
misc:removing the empty directories
13 years, 8 months
teiid SVN: r3087 - in trunk: documentation/admin-guide/src/main/docbook/en-US/content and 1 other directory.
by teiid-commits@lists.jboss.org
Author: rareddy
Date: 2011-04-13 13:06:41 -0400 (Wed, 13 Apr 2011)
New Revision: 3087
Modified:
trunk/build/kits/jboss-container/conf/jboss-teiid-log4j.xml
trunk/documentation/admin-guide/src/main/docbook/en-US/content/logging.xml
Log:
TEIID-1551: documenting the ODBC logging context
Modified: trunk/build/kits/jboss-container/conf/jboss-teiid-log4j.xml
===================================================================
--- trunk/build/kits/jboss-container/conf/jboss-teiid-log4j.xml 2011-04-13 16:28:17 UTC (rev 3086)
+++ trunk/build/kits/jboss-container/conf/jboss-teiid-log4j.xml 2011-04-13 17:06:41 UTC (rev 3087)
@@ -38,6 +38,8 @@
org.teiid.AUDIT_LOG - Authorization enforcement events.
org.teiid.ADMIN_API - Admin API logs.
+
+ org.teiid.ODBC - ODBC logs
-->
<!--
Modified: trunk/documentation/admin-guide/src/main/docbook/en-US/content/logging.xml
===================================================================
--- trunk/documentation/admin-guide/src/main/docbook/en-US/content/logging.xml 2011-04-13 16:28:17 UTC (rev 3086)
+++ trunk/documentation/admin-guide/src/main/docbook/en-US/content/logging.xml 2011-04-13 17:06:41 UTC (rev 3087)
@@ -159,6 +159,14 @@
<para>Admin API logs.</para>
</entry>
</row>
+ <row>
+ <entry>
+ <para>org.teiid.ODBC</para>
+ </entry>
+ <entry>
+ <para>ODBC logs.</para>
+ </entry>
+ </row>
</tbody>
</tgroup>
</informaltable>
13 years, 8 months
teiid SVN: r3086 - in trunk/documentation: reference/src/main/docbook/en-US/content and 1 other directory.
by teiid-commits@lists.jboss.org
Author: shawkins
Date: 2011-04-13 12:28:17 -0400 (Wed, 13 Apr 2011)
New Revision: 3086
Modified:
trunk/documentation/client-developers-guide/src/main/docbook/en-US/content/jdbc-connection.xml
trunk/documentation/reference/src/main/docbook/en-US/content/scalar_functions.xml
Log:
minor doc updates on trim functions and use of an external load balancer
Modified: trunk/documentation/client-developers-guide/src/main/docbook/en-US/content/jdbc-connection.xml
===================================================================
--- trunk/documentation/client-developers-guide/src/main/docbook/en-US/content/jdbc-connection.xml 2011-04-13 03:31:08 UTC (rev 3085)
+++ trunk/documentation/client-developers-guide/src/main/docbook/en-US/content/jdbc-connection.xml 2011-04-13 16:28:17 UTC (rev 3086)
@@ -529,6 +529,8 @@
It's important to consider that 1 <code>ServerDiscovery</code> instance will be created for each connection. Any sharing of information between instances should be done through static state or some other shared lookup.
</para>
<para>Your customized server discovery class will then need to be referenced by the discoveryStategy connection/DataSource property by its full class name.</para>
+ <para>You may also choose to use an external tcp load balancer, such as <ulink url="http://haproxy.1wt.eu/">haproxy</ulink>.
+ The Teiid driver/DataSource should then typically be configured to just use the single host/port of your load balancer.</para>
</section>
</section>
<section>
Modified: trunk/documentation/reference/src/main/docbook/en-US/content/scalar_functions.xml
===================================================================
--- trunk/documentation/reference/src/main/docbook/en-US/content/scalar_functions.xml 2011-04-13 03:31:08 UTC (rev 3085)
+++ trunk/documentation/reference/src/main/docbook/en-US/content/scalar_functions.xml 2011-04-13 16:28:17 UTC (rev 3086)
@@ -913,7 +913,7 @@
<para>LTRIM(x)</para>
</entry>
<entry>
- <para>Left trim x of white space</para>
+ <para>Left trim x of blank chars</para>
</entry>
<entry>
<para>x in {string}, return string</para>
@@ -996,7 +996,7 @@
<para>RTRIM(x)</para>
</entry>
<entry>
- <para>Right trim x of white space</para>
+ <para>Right trim x of blank chars</para>
</entry>
<entry>
<para>x is string, return string</para>
13 years, 8 months
teiid SVN: r3085 - in branches/7.1.x: build and 20 other directories.
by teiid-commits@lists.jboss.org
Author: rareddy
Date: 2011-04-12 23:31:08 -0400 (Tue, 12 Apr 2011)
New Revision: 3085
Added:
branches/7.1.x/client-jdk15/
branches/7.1.x/client-jdk15/pom.xml
branches/7.1.x/client-jdk15/src/
branches/7.1.x/client-jdk15/src/main/
branches/7.1.x/client-jdk15/src/main/java/
branches/7.1.x/client-jdk15/src/main/java/net/
branches/7.1.x/client-jdk15/src/main/java/net/sf/
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/io/
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/io/_IOException.java
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/io/_ObjectStreamClass.java
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/NClob_.java
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/RowId_.java
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/SQLClientInfoException_.java
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/SQLFeatureNotSupportedException_.java
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/SQLXML_.java
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/Wrapper_.java
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/_SQLException.java
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/_SQLWarning.java
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/_Types.java
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/util/
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/util/_Properties.java
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/javax/
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/javax/net/
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/javax/net/ssl/
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/javax/net/ssl/_SSLContext.java
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/org/
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/org/teiid/
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/org/teiid/core/
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/org/teiid/core/types/
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/org/teiid/core/types/basic/
branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/org/teiid/core/types/basic/StringToSQLXMLTransform_.java
Modified:
branches/7.1.x/build/pom.xml
branches/7.1.x/pom.xml
Log:
SOA-2999: Adding support to produce JDK1.5 compatible Client JDBC driver to the build
Modified: branches/7.1.x/build/pom.xml
===================================================================
--- branches/7.1.x/build/pom.xml 2011-04-12 23:20:51 UTC (rev 3084)
+++ branches/7.1.x/build/pom.xml 2011-04-13 03:31:08 UTC (rev 3085)
@@ -8,6 +8,24 @@
<artifactId>teiid</artifactId>
<name>Build</name>
<description>Teiid Build</description>
+ <dependencies>
+ <dependency>
+ <groupId>org.jboss.teiid</groupId>
+ <artifactId>teiid-client-jdk15</artifactId>
+ <version>${version}</version>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.retrotranslator</groupId>
+ <artifactId>retrotranslator-runtime</artifactId>
+ <version>1.2.9</version>
+ </dependency>
+
+ <dependency>
+ <groupId>net.sf.retrotranslator</groupId>
+ <artifactId>retrotranslator-transformer</artifactId>
+ <version>1.2.9</version>
+ </dependency>
+ </dependencies>
<build>
<outputDirectory>target/kits</outputDirectory>
<resources>
@@ -86,8 +104,33 @@
</descriptors>
</configuration>
</plugin>
+
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>exec-maven-plugin</artifactId>
+ <version>1.1.1</version>
+ <executions>
+ <execution>
+ <phase>package</phase>
+ <goals>
+ <goal>java</goal>
+ </goals>
+ <configuration>
+ <mainClass>net.sf.retrotranslator.transformer.Retrotranslator</mainClass>
+ <arguments>
+ <argument>-srcjar</argument>
+ <argument>${pom.basedir}/target/teiid-${pom.version}-client.jar</argument>
+ <argument>-destjar</argument>
+ <argument>${pom.basedir}/target/teiid-${pom.version}-client-jdk15.jar</argument>
+ <argument>-embed</argument>
+ <argument>org.teiid.retroruntime</argument>
+ </arguments>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
</plugins>
</build>
</profile>
</profiles>
-</project>
\ No newline at end of file
+</project>
Added: branches/7.1.x/client-jdk15/pom.xml
===================================================================
--- branches/7.1.x/client-jdk15/pom.xml (rev 0)
+++ branches/7.1.x/client-jdk15/pom.xml 2011-04-13 03:31:08 UTC (rev 3085)
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <parent>
+ <artifactId>teiid-parent</artifactId>
+ <groupId>org.jboss.teiid</groupId>
+ <version>7.1.1.GA</version>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+ <artifactId>teiid-client-jdk15</artifactId>
+ <name>Client JDK15</name>
+ <description>Contains the packages related retrotranslator that will convert 1.6 to 1.5</description>
+ <dependencies>
+ <dependency>
+ <groupId>org.jboss.teiid</groupId>
+ <artifactId>teiid-common-core</artifactId>
+ </dependency>
+ </dependencies>
+</project>
Added: branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/io/_IOException.java
===================================================================
--- branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/io/_IOException.java (rev 0)
+++ branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/io/_IOException.java 2011-04-13 03:31:08 UTC (rev 3085)
@@ -0,0 +1,33 @@
+/*
+ * JBoss, Home of Professional Open Source
+ *
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @author tags. See the COPYRIGHT.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package net.sf.retrotranslator.runtime.java.io;
+
+import java.io.IOException;
+
+public class _IOException {
+ public static IOException createNewInstance(Throwable t){
+ IOException io = new IOException();
+ io.initCause(t);
+ return io;
+ }
+}
Added: branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/io/_ObjectStreamClass.java
===================================================================
--- branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/io/_ObjectStreamClass.java (rev 0)
+++ branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/io/_ObjectStreamClass.java 2011-04-13 03:31:08 UTC (rev 3085)
@@ -0,0 +1,38 @@
+/*
+ * JBoss, Home of Professional Open Source
+ *
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @author tags. See the COPYRIGHT.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package net.sf.retrotranslator.runtime.java.io;
+
+import java.io.ObjectStreamClass;
+import java.lang.reflect.Method;
+
+public class _ObjectStreamClass {
+ public static ObjectStreamClass lookupAny(Class<?> cl) {
+ try {
+ Method m = ObjectStreamClass.class.getDeclaredMethod("lookup",new Class[] { Class.class, Boolean.TYPE }); //$NON-NLS-1$
+ m.setAccessible(true);
+ return (ObjectStreamClass) m.invoke(null, new Object[] { cl,Boolean.valueOf(true) });
+ } catch (Exception e) {
+ throw new RuntimeException(e);
+ }
+ }
+}
Added: branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/NClob_.java
===================================================================
--- branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/NClob_.java (rev 0)
+++ branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/NClob_.java 2011-04-13 03:31:08 UTC (rev 3085)
@@ -0,0 +1,29 @@
+/*
+ * JBoss, Home of Professional Open Source
+ *
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @author tags. See the COPYRIGHT.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package net.sf.retrotranslator.runtime.java.sql;
+
+import java.sql.Clob;
+
+public abstract interface NClob_ extends Clob
+{
+}
\ No newline at end of file
Added: branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/RowId_.java
===================================================================
--- branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/RowId_.java (rev 0)
+++ branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/RowId_.java 2011-04-13 03:31:08 UTC (rev 3085)
@@ -0,0 +1,30 @@
+/*
+ * JBoss, Home of Professional Open Source
+ *
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @author tags. See the COPYRIGHT.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package net.sf.retrotranslator.runtime.java.sql;
+
+public interface RowId_ {
+ boolean equals(Object obj);
+ byte[] getBytes();
+ String toString();
+ int hashCode();
+}
Added: branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/SQLClientInfoException_.java
===================================================================
--- branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/SQLClientInfoException_.java (rev 0)
+++ branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/SQLClientInfoException_.java 2011-04-13 03:31:08 UTC (rev 3085)
@@ -0,0 +1,29 @@
+/*
+ * JBoss, Home of Professional Open Source
+ *
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @author tags. See the COPYRIGHT.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package net.sf.retrotranslator.runtime.java.sql;
+
+import java.sql.SQLException;
+
+public class SQLClientInfoException_ extends SQLException {
+
+}
Added: branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/SQLFeatureNotSupportedException_.java
===================================================================
--- branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/SQLFeatureNotSupportedException_.java (rev 0)
+++ branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/SQLFeatureNotSupportedException_.java 2011-04-13 03:31:08 UTC (rev 3085)
@@ -0,0 +1,29 @@
+/*
+ * JBoss, Home of Professional Open Source
+ *
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @author tags. See the COPYRIGHT.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package net.sf.retrotranslator.runtime.java.sql;
+
+import java.sql.SQLException;
+
+public class SQLFeatureNotSupportedException_ extends SQLException {
+
+}
Added: branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/SQLXML_.java
===================================================================
--- branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/SQLXML_.java (rev 0)
+++ branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/SQLXML_.java 2011-04-13 03:31:08 UTC (rev 3085)
@@ -0,0 +1,61 @@
+/*
+ * JBoss, Home of Professional Open Source
+ *
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @author tags. See the COPYRIGHT.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package net.sf.retrotranslator.runtime.java.sql;
+
+import java.io.InputStream;
+import java.io.OutputStream;
+import java.io.Reader;
+import java.io.Writer;
+import java.sql.SQLException;
+import javax.xml.transform.Result;
+import javax.xml.transform.Source;
+
+public abstract interface SQLXML_
+{
+ public abstract void free()
+ throws SQLException;
+
+ public abstract InputStream getBinaryStream()
+ throws SQLException;
+
+ public abstract OutputStream setBinaryStream()
+ throws SQLException;
+
+ public abstract Reader getCharacterStream()
+ throws SQLException;
+
+ public abstract Writer setCharacterStream()
+ throws SQLException;
+
+ public abstract String getString()
+ throws SQLException;
+
+ public abstract void setString(String paramString)
+ throws SQLException;
+
+ public abstract <T extends Source> T getSource(Class<T> paramClass)
+ throws SQLException;
+
+ public abstract <T extends Result> T setResult(Class<T> paramClass)
+ throws SQLException;
+}
\ No newline at end of file
Added: branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/Wrapper_.java
===================================================================
--- branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/Wrapper_.java (rev 0)
+++ branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/Wrapper_.java 2011-04-13 03:31:08 UTC (rev 3085)
@@ -0,0 +1,34 @@
+/*
+ * JBoss, Home of Professional Open Source
+ *
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @author tags. See the COPYRIGHT.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package net.sf.retrotranslator.runtime.java.sql;
+
+import java.sql.SQLException;
+
+public abstract interface Wrapper_
+{
+ public abstract <T> T unwrap(Class<T> paramClass)
+ throws SQLException;
+
+ public abstract boolean isWrapperFor(Class<?> paramClass)
+ throws SQLException;
+}
\ No newline at end of file
Added: branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/_SQLException.java
===================================================================
--- branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/_SQLException.java (rev 0)
+++ branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/_SQLException.java 2011-04-13 03:31:08 UTC (rev 3085)
@@ -0,0 +1,33 @@
+/*
+ * JBoss, Home of Professional Open Source
+ *
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @author tags. See the COPYRIGHT.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package net.sf.retrotranslator.runtime.java.sql;
+
+import java.sql.SQLException;
+
+public class _SQLException {
+ public static SQLException createNewInstance(Throwable t){
+ SQLException sql = new SQLException();
+ sql.initCause(t);
+ return sql;
+ }
+}
Added: branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/_SQLWarning.java
===================================================================
--- branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/_SQLWarning.java (rev 0)
+++ branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/_SQLWarning.java 2011-04-13 03:31:08 UTC (rev 3085)
@@ -0,0 +1,33 @@
+/*
+ * JBoss, Home of Professional Open Source
+ *
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @author tags. See the COPYRIGHT.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package net.sf.retrotranslator.runtime.java.sql;
+
+import java.sql.SQLWarning;
+
+public class _SQLWarning {
+ public static SQLWarning createNewInstance(Throwable t){
+ SQLWarning sql = new SQLWarning();
+ sql.initCause(t);
+ return sql;
+ }
+}
Added: branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/_Types.java
===================================================================
--- branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/_Types.java (rev 0)
+++ branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/sql/_Types.java 2011-04-13 03:31:08 UTC (rev 3085)
@@ -0,0 +1,32 @@
+/*
+ * JBoss, Home of Professional Open Source
+ *
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @author tags. See the COPYRIGHT.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package net.sf.retrotranslator.runtime.java.sql;
+
+public class _Types {
+ public final static int ROWID = -8;
+ public static final int NCHAR = -15;
+ public static final int NVARCHAR = -9;
+ public static final int LONGNVARCHAR = -16;
+ public static final int NCLOB = 2011;
+ public static final int SQLXML = 2009;
+}
Added: branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/util/_Properties.java
===================================================================
--- branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/util/_Properties.java (rev 0)
+++ branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/java/util/_Properties.java 2011-04-13 03:31:08 UTC (rev 3085)
@@ -0,0 +1,36 @@
+/*
+ * JBoss, Home of Professional Open Source
+ *
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @author tags. See the COPYRIGHT.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package net.sf.retrotranslator.runtime.java.util;
+
+import java.util.Collections;
+import java.util.Enumeration;
+import java.util.HashSet;
+import java.util.Properties;
+import java.util.Set;
+
+public class _Properties {
+
+ public static Set<String> stringPropertyNames(Properties props) {
+ return new HashSet<String>(Collections.list((Enumeration<String>)props.propertyNames()));
+ }
+}
Added: branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/javax/net/ssl/_SSLContext.java
===================================================================
--- branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/javax/net/ssl/_SSLContext.java (rev 0)
+++ branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/javax/net/ssl/_SSLContext.java 2011-04-13 03:31:08 UTC (rev 3085)
@@ -0,0 +1,33 @@
+/*
+ * JBoss, Home of Professional Open Source
+ *
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @author tags. See the COPYRIGHT.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package net.sf.retrotranslator.runtime.javax.net.ssl;
+
+import java.security.NoSuchAlgorithmException;
+
+import javax.net.ssl.SSLContext;
+
+public class _SSLContext {
+ public static SSLContext getDefault() throws NoSuchAlgorithmException {
+ return SSLContext.getInstance("TLSv1"); //$NON-NLS-1$
+ }
+}
Added: branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/org/teiid/core/types/basic/StringToSQLXMLTransform_.java
===================================================================
--- branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/org/teiid/core/types/basic/StringToSQLXMLTransform_.java (rev 0)
+++ branches/7.1.x/client-jdk15/src/main/java/net/sf/retrotranslator/runtime/org/teiid/core/types/basic/StringToSQLXMLTransform_.java 2011-04-13 03:31:08 UTC (rev 3085)
@@ -0,0 +1,72 @@
+/*
+ * JBoss, Home of Professional Open Source
+ *
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @author tags. See the COPYRIGHT.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package net.sf.retrotranslator.runtime.org.teiid.core.types.basic;
+
+import java.io.Reader;
+
+import org.teiid.core.types.DataTypeManager;
+import org.teiid.core.types.Transform;
+import org.teiid.core.types.TransformationException;
+import org.teiid.core.types.XMLType.Type;
+
+public class StringToSQLXMLTransform_ extends Transform {
+
+ public static Type isXml(Reader reader) throws TransformationException {
+ return Type.UNKNOWN;
+ }
+
+ /**
+ * This method transforms a value of the source type into a value
+ * of the target type.
+ * @param value Incoming value of source type
+ * @return Outgoing value of target type
+ * @throws TransformationException if value is an incorrect input type or
+ * the transformation fails
+ */
+ public Object transformDirect(Object value) throws TransformationException {
+ throw new UnsupportedOperationException();
+ }
+
+
+
+ /**
+ * Type of the incoming value.
+ * @return Source type
+ */
+ public Class<?> getSourceType() {
+ return DataTypeManager.DefaultDataClasses.STRING;
+ }
+
+ /**
+ * Type of the outgoing value.
+ * @return Target type
+ */
+ public Class<?> getTargetType() {
+ return DataTypeManager.DefaultDataClasses.XML;
+ }
+
+ @Override
+ public boolean isExplicit() {
+ return true;
+ }
+}
Modified: branches/7.1.x/pom.xml
===================================================================
--- branches/7.1.x/pom.xml 2011-04-12 23:20:51 UTC (rev 3084)
+++ branches/7.1.x/pom.xml 2011-04-13 03:31:08 UTC (rev 3085)
@@ -470,8 +470,9 @@
<module>adminshell</module>
<module>cache-jbosscache</module>
<module>hibernate-dialect</module>
- <module>jboss-integration</module>
+ <module>jboss-integration</module>
<module>test-integration</module>
+ <module>client-jdk15</module>
</modules>
<distributionManagement>
<repository>
@@ -485,4 +486,4 @@
<url>https://repository.jboss.org/nexus/content/repositories/snapshots/</url>
</snapshotRepository>
</distributionManagement>
-</project>
\ No newline at end of file
+</project>
13 years, 8 months
teiid SVN: r3084 - in trunk: engine/src/main/java/org/teiid/query/function/aggregate and 16 other directories.
by teiid-commits@lists.jboss.org
Author: rareddy
Date: 2011-04-12 19:20:51 -0400 (Tue, 12 Apr 2011)
New Revision: 3084
Added:
trunk/engine/src/main/java/org/teiid/query/function/aggregate/ArrayAgg.java
trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestODBCProceduresSchema.java
trunk/test-integration/common/src/test/resources/bqt.vdb
Removed:
trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_PROC.expected
Modified:
trunk/api/src/main/java/org/teiid/language/SQLConstants.java
trunk/engine/src/main/java/org/teiid/query/processor/relational/GroupingNode.java
trunk/engine/src/main/java/org/teiid/query/sql/symbol/AggregateSymbol.java
trunk/engine/src/main/javacc/org/teiid/query/parser/SQLParser.jj
trunk/engine/src/test/java/org/teiid/query/parser/TestParser.java
trunk/runtime/src/main/java/org/teiid/deployers/CompositeVDB.java
trunk/runtime/src/main/java/org/teiid/deployers/PgCatalogMetadataStore.java
trunk/runtime/src/main/java/org/teiid/odbc/ODBCServerRemoteImpl.java
trunk/runtime/src/main/java/org/teiid/transport/PgBackendProtocol.java
trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestODBCSchema.java
trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestSystemVirtualModel.java
trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestVirtualDocWithVirtualProc.java
trunk/test-integration/common/src/test/java/org/teiid/transport/TestODBCSocketTransport.java
trunk/test-integration/common/src/test/resources/TestCase3473/testGetTables.expected
trunk/test-integration/common/src/test/resources/TestMMDatabaseMetaData/testGetColumns.expected
trunk/test-integration/common/src/test/resources/TestMMDatabaseMetaData/testGetTables.expected
trunk/test-integration/common/src/test/resources/TestMMDatabaseMetaData/testGetTables_allTables.expected
trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_ATTRIBUTE.expected
trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_CLASS.expected
trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_INDEX.expected
trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_TYPE.expected
trunk/test-integration/common/src/test/resources/TestODBCSocketTransport/testSelect.expected
trunk/test-integration/common/src/test/resources/TestPartsDatabaseMetadata/testColumns.expected
trunk/test-integration/common/src/test/resources/TestPartsDatabaseMetadata/testIndexInfo.expected
trunk/test-integration/common/src/test/resources/TestPartsDatabaseMetadata/testPrimaryKeys.expected
trunk/test-integration/common/src/test/resources/TestPartsDatabaseMetadata/testTables.expected
trunk/test-integration/common/src/test/resources/TestSystemVirtualModel/testColumns.expected
trunk/test-integration/common/src/test/resources/TestSystemVirtualModel/testKeyColumns.expected
trunk/test-integration/common/src/test/resources/TestSystemVirtualModel/testKeys.expected
trunk/test-integration/common/src/test/resources/TestSystemVirtualModel/testTables.expected
Log:
TEIID-1164: adding parameter metadata support for procedures. This required adding additional data types, implementing a array_agg function.
Modified: trunk/api/src/main/java/org/teiid/language/SQLConstants.java
===================================================================
--- trunk/api/src/main/java/org/teiid/language/SQLConstants.java 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/api/src/main/java/org/teiid/language/SQLConstants.java 2011-04-12 23:20:51 UTC (rev 3084)
@@ -357,6 +357,9 @@
public static final String WITHIN = "WITHIN"; //$NON-NLS-1$
public static final String WITHOUT = "WITHOUT"; //$NON-NLS-1$
public static final String YEAR = "YEAR"; //$NON-NLS-1$
+
+ // SQL 2008 words
+ public static final String ARRAY_AGG= "ARRAY_AGG"; //$NON-NLS-1$
//SQL/XML
Added: trunk/engine/src/main/java/org/teiid/query/function/aggregate/ArrayAgg.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/query/function/aggregate/ArrayAgg.java (rev 0)
+++ trunk/engine/src/main/java/org/teiid/query/function/aggregate/ArrayAgg.java 2011-04-12 23:20:51 UTC (rev 3084)
@@ -0,0 +1,68 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * See the COPYRIGHT.txt file distributed with this work for information
+ * regarding copyright ownership. Some portions may be licensed
+ * to Red Hat, Inc. under one or more contributor license agreements.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA.
+ */
+package org.teiid.query.function.aggregate;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.teiid.api.exception.query.ExpressionEvaluationException;
+import org.teiid.api.exception.query.FunctionExecutionException;
+import org.teiid.core.TeiidComponentException;
+import org.teiid.core.TeiidProcessingException;
+import org.teiid.query.util.CommandContext;
+
+public class ArrayAgg extends AggregateFunction {
+
+ private ArrayList<Object> result;
+ private CommandContext context;
+
+ public ArrayAgg(CommandContext context) {
+ this.context = context;
+ }
+
+ @Override
+ public void addInputDirect(Object input, List<?> tuple) throws TeiidComponentException, TeiidProcessingException {
+ if (this.result == null) {
+ this.result = new ArrayList<Object>();
+ }
+ this.result.add(input);
+ }
+
+ @Override
+ public Object getResult() throws FunctionExecutionException, ExpressionEvaluationException, TeiidComponentException,TeiidProcessingException {
+ if (this.result == null) {
+ return null;
+ }
+ return this.result.toArray();
+ }
+
+ @Override
+ public void reset() {
+ this.result = null;
+ }
+
+ @Override
+ boolean filter(Object value) {
+ // handle the null values too.
+ return false;
+ }
+}
Property changes on: trunk/engine/src/main/java/org/teiid/query/function/aggregate/ArrayAgg.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Modified: trunk/engine/src/main/java/org/teiid/query/processor/relational/GroupingNode.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/query/processor/relational/GroupingNode.java 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/engine/src/main/java/org/teiid/query/processor/relational/GroupingNode.java 2011-04-12 23:20:51 UTC (rev 3084)
@@ -44,6 +44,7 @@
import org.teiid.language.SQLConstants.NonReserved;
import org.teiid.query.eval.Evaluator;
import org.teiid.query.function.aggregate.AggregateFunction;
+import org.teiid.query.function.aggregate.ArrayAgg;
import org.teiid.query.function.aggregate.Avg;
import org.teiid.query.function.aggregate.ConstantFunction;
import org.teiid.query.function.aggregate.Count;
@@ -189,6 +190,9 @@
case XMLAGG:
functions[i] = new XMLAgg(context);
break;
+ case ARRAY_AGG:
+ functions[i] = new ArrayAgg(context);
+ break;
case TEXTAGG:
functions[i] = new TextAgg(context, (TextLine)ex);
break;
Modified: trunk/engine/src/main/java/org/teiid/query/sql/symbol/AggregateSymbol.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/query/sql/symbol/AggregateSymbol.java 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/engine/src/main/java/org/teiid/query/sql/symbol/AggregateSymbol.java 2011-04-12 23:20:51 UTC (rev 3084)
@@ -62,6 +62,7 @@
MAX,
XMLAGG,
TEXTAGG,
+ ARRAY_AGG,
ANY,
SOME,
EVERY,
@@ -176,6 +177,8 @@
return DataTypeManager.DefaultDataClasses.BOOLEAN;
} else if (isEnhancedNumeric()) {
return DataTypeManager.DefaultDataClasses.DOUBLE;
+ } else if (this.aggregate == Type.ARRAY_AGG) {
+ return DataTypeManager.DefaultDataClasses.OBJECT;
} else {
return this.getExpression().getType();
}
Modified: trunk/engine/src/main/javacc/org/teiid/query/parser/SQLParser.jj
===================================================================
--- trunk/engine/src/main/javacc/org/teiid/query/parser/SQLParser.jj 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/engine/src/main/javacc/org/teiid/query/parser/SQLParser.jj 2011-04-12 23:20:51 UTC (rev 3084)
@@ -102,6 +102,7 @@
| <AND: "and">
| <ANY: "any">
| <ARRAY: "array">
+| <ARRAY_AGG: "array_agg">
| <AS: "as">
| <ASC: "asc">
| <ATOMIC: "atomic">
@@ -389,6 +390,8 @@
| <RPAREN: ")">
| <LBRACE: "{">
| <RBRACE: "}">
+| <LSBRACE: "[">
+| <RSBRACE: "]">
| <EQ: "=">
| <NE: "<>">
| <NE2: "!=">
@@ -1869,7 +1872,31 @@
}
}
+AggregateSymbol arrayAgg(ParseInfo info) :
+{
+ Expression expression = null;
+ OrderBy orderBy = null;
+}
+{
+ <ARRAY_AGG> <LPAREN>
+ expression = expression(info)
+ [
+ orderBy = orderby(info)
+ ]
+ <RPAREN>
+ {
+ if(! info.aggregatesAllowed) {
+ throw new ParseException(QueryPlugin.Util.getString("SQLParser.Aggregate_only_top_level")); //$NON-NLS-1$
+ }
+
+ String name = generateFunctionName(info, "ARRAY_AGG");
+ AggregateSymbol agg = new AggregateSymbol(name, "ARRAY_AGG", false, expression);
+ agg.setOrderBy(orderBy);
+ return agg;
+ }
+}
+
AggregateSymbol textAgg(ParseInfo info) :
{
DerivedColumn expression = null;
@@ -3294,6 +3321,7 @@
Token symbol = null;
Constant literal = null;
QueryCommand subquery = null;
+ Integer arrayIndex = null;
}
{
(
@@ -3311,8 +3339,8 @@
<RBRACE>
)
|
- LOOKAHEAD(<ID> <LPAREN> <FOR>) (expression=textAgg(info))
- |
+ LOOKAHEAD(<ID> <LPAREN> <FOR>) (expression=textAgg(info))
+ |
// Aggregate function
LOOKAHEAD(<ID>, {matchesAny(getToken(1).image, "count", "min", "max", "sum", "avg", "every", "STDDEV_POP", "STDDEV_SAMP", "VAR_SAMP", "VAR_POP") != null}) (expression=aggregateSymbol(info))
|
@@ -3322,6 +3350,8 @@
|
(expression=xmlAgg(info))
|
+ (expression=arrayAgg(info))
+ |
// Function
LOOKAHEAD(2) (expression=function(info))
|
@@ -3334,6 +3364,7 @@
symbol = null;
}
}
+ (<LSBRACE> arrayIndex = intVal() <RSBRACE>)?
)
|
LOOKAHEAD(subquery(info)) subquery = subquery(info)
@@ -3341,6 +3372,7 @@
( <LPAREN>
expression = expression(info)
<RPAREN>
+ (<LSBRACE> arrayIndex = intVal() <RSBRACE>)?
)
|
// Searched CASE expressions
@@ -3355,16 +3387,18 @@
if (refToken.image.charAt(0) == '$') {
return new Reference(Integer.parseInt(refToken.image.substring(1)) -1);
}
- return new Reference(info.referenceCount++);
+ expression = new Reference(info.referenceCount++);
} else if(symbol != null) {
- return new ElementSymbol(normalizeId(symbol.image));
+ expression = new ElementSymbol(normalizeId(symbol.image));
} else if(literal != null) {
- return literal; // may be null literal
+ expression = literal; // may be null literal
} else if (subquery != null){
- return new ScalarSubquery(subquery);
- } else {
- return expression;
+ expression = new ScalarSubquery(subquery);
}
+ if (arrayIndex != null) {
+ expression = new Function("array_get", new Expression[] {expression, new Constant(arrayIndex)});
+ }
+ return expression;
}
}
Modified: trunk/engine/src/test/java/org/teiid/query/parser/TestParser.java
===================================================================
--- trunk/engine/src/test/java/org/teiid/query/parser/TestParser.java 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/engine/src/test/java/org/teiid/query/parser/TestParser.java 2011-04-12 23:20:51 UTC (rev 3084)
@@ -6749,6 +6749,24 @@
helpTest(sql, "SELECT TEXTAGG(FOR e1 AS col1, e2 AS col2 DELIMITER ',' HEADER ORDER BY e2)", query);
}
+ @Test public void testArrayAggWithOrderBy() throws Exception {
+ String sql = "SELECT array_agg(1 order by e2)"; //$NON-NLS-1$
+ AggregateSymbol as = new AggregateSymbol("foo", Reserved.ARRAY_AGG, false, new Constant(1));
+ as.setOrderBy(new OrderBy(Arrays.asList(new ElementSymbol("e2"))));
+ Query query = new Query();
+ query.setSelect(new Select(Arrays.asList(as)));
+ helpTest(sql, "SELECT ARRAY_AGG(1 ORDER BY e2)", query);
+ }
+
+ @Test public void testArrayAggWithIndexing() throws Exception {
+ String sql = "SELECT (array_agg(1))[1]"; //$NON-NLS-1$
+ AggregateSymbol as = new AggregateSymbol("foo", Reserved.ARRAY_AGG, false, new Constant(1));
+ ExpressionSymbol expr = new ExpressionSymbol("expr", new Function("array_get", new Expression[] {as, new Constant(1)}));
+ Query query = new Query();
+ query.setSelect(new Select(Arrays.asList(expr)));
+ helpTest(sql, "SELECT array_get(ARRAY_AGG(1), 1)", query);
+ }
+
@Test public void testNestedTable() throws Exception {
String sql = "SELECT * from TABLE(exec foo()) as x"; //$NON-NLS-1$
Query query = new Query();
Modified: trunk/runtime/src/main/java/org/teiid/deployers/CompositeVDB.java
===================================================================
--- trunk/runtime/src/main/java/org/teiid/deployers/CompositeVDB.java 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/runtime/src/main/java/org/teiid/deployers/CompositeVDB.java 2011-04-12 23:20:51 UTC (rev 3084)
@@ -109,6 +109,11 @@
CompositeMetadataStore compositeStore = new CompositeMetadataStore(stores.getStores());
for (MetadataStore s:this.additionalStores) {
compositeStore.addMetadataStore(s);
+ for (Schema schema:s.getSchemas().values()) {
+ if (!schema.getFunctions().isEmpty()) {
+ udfs.add(new FunctionTree(schema.getName(), new UDFSource(schema.getFunctions().values()), true));
+ }
+ }
}
TransformationMetadata metadata = new TransformationMetadata(vdb, compositeStore, visibilityMap, systemFunctions, udfs);
Modified: trunk/runtime/src/main/java/org/teiid/deployers/PgCatalogMetadataStore.java
===================================================================
--- trunk/runtime/src/main/java/org/teiid/deployers/PgCatalogMetadataStore.java 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/runtime/src/main/java/org/teiid/deployers/PgCatalogMetadataStore.java 2011-04-12 23:20:51 UTC (rev 3084)
@@ -22,6 +22,7 @@
package org.teiid.deployers;
import java.math.BigInteger;
+import java.util.ArrayList;
import java.util.Arrays;
import java.util.Map;
import java.util.Properties;
@@ -30,13 +31,22 @@
import org.teiid.core.types.DataTypeManager;
import org.teiid.metadata.AbstractMetadataRecord;
+import org.teiid.metadata.Column;
import org.teiid.metadata.Datatype;
+import org.teiid.metadata.FunctionMethod;
+import org.teiid.metadata.FunctionParameter;
import org.teiid.metadata.MetadataFactory;
import org.teiid.metadata.Table;
+import org.teiid.metadata.FunctionMethod.PushDown;
import org.teiid.metadata.Table.Type;
import org.teiid.translator.TranslatorException;
public class PgCatalogMetadataStore extends MetadataFactory {
+
+ public static final int PG_TYPE_OIDVECTOR = 30;
+ public static final int PG_TYPE_OIDARRAY = 1028;
+ public static final int PG_TYPE_CHARARRAY = 1002;
+ public static final int PG_TYPE_TEXTARRAY = 1009;
private static final long serialVersionUID = 5391872008395637166L;
private Random random;
@@ -56,6 +66,8 @@
add_pg_database();
add_pg_user();
add_matpg_relatt();
+ add_matpg_datatype();
+ addHasFunctionPrivilage();
}
@Override
@@ -154,13 +166,7 @@
"false as atthasdef " + //$NON-NLS-1$
"FROM SYS.Columns as t1 LEFT OUTER JOIN " + //$NON-NLS-1$
"SYS.Tables st ON (st.Name = t1.TableName AND st.SchemaName = t1.SchemaName) LEFT OUTER JOIN " + //$NON-NLS-1$
- "pg_catalog.pg_type pt ON (CASE " +//$NON-NLS-1$
- "WHEN (t1.DataType = 'clob' OR t1.DataType = 'blob') THEN 'lo' " +//$NON-NLS-1$
- "WHEN (t1.DataType = 'byte' ) THEN 'short' " + //$NON-NLS-1$
- "WHEN (t1.DataType = 'time' ) THEN 'datetime' " + //$NON-NLS-1$
- "WHEN (t1.DataType = 'biginteger' ) THEN 'decimal' " + //$NON-NLS-1$
- "WHEN (t1.DataType = 'bigdecimal' ) THEN 'decimal' " + //$NON-NLS-1$
- "ELSE t1.DataType END = pt.typname)"; //$NON-NLS-1$
+ "pg_catalog.matpg_datatype pt ON t1.DataType = pt.Name";//$NON-NLS-1$
t.setSelectTransformation(transformation);
t.setMaterialized(true);
return t;
@@ -285,31 +291,49 @@
// Number of input arguments
addColumn("pronargs", DataTypeManager.DefaultDataTypes.SHORT, t); //$NON-NLS-1$
- addColumn("proargtypes", DataTypeManager.DefaultDataTypes.OBJECT, t); //$NON-NLS-1$
- addColumn("proargnames", DataTypeManager.DefaultDataTypes.OBJECT, t); //$NON-NLS-1$
- addColumn("proargmodes", DataTypeManager.DefaultDataTypes.OBJECT, t); //$NON-NLS-1$
- addColumn("proallargtypes", DataTypeManager.DefaultDataTypes.OBJECT, t); //$NON-NLS-1$
+ Column c = addColumn("proargtypes", DataTypeManager.DefaultDataTypes.OBJECT, t); //$NON-NLS-1$
+ c.setProperty("pg_type:oid", String.valueOf(PG_TYPE_OIDVECTOR)); //$NON-NLS-1$
+ c = addColumn("proargnames", DataTypeManager.DefaultDataTypes.OBJECT, t); //$NON-NLS-1$
+ c.setProperty("pg_type:oid", String.valueOf(PG_TYPE_TEXTARRAY)); //$NON-NLS-1$
+
+ c = addColumn("proargmodes", DataTypeManager.DefaultDataTypes.OBJECT, t); //$NON-NLS-1$
+ c.setProperty("pg_type:oid", String.valueOf(PG_TYPE_CHARARRAY)); //$NON-NLS-1$
+
+ c = addColumn("proallargtypes", DataTypeManager.DefaultDataTypes.OBJECT, t); //$NON-NLS-1$
+ c.setProperty("pg_type:oid", String.valueOf(PG_TYPE_OIDARRAY)); //$NON-NLS-1$
+
// The OID of the namespace that contains this function
addColumn("pronamespace", DataTypeManager.DefaultDataTypes.INTEGER, t); //$NON-NLS-1$
addPrimaryKey("pk_pg_proc", Arrays.asList("oid"), t); //$NON-NLS-1$ //$NON-NLS-2$
- String transformation = "SELECT t1.OID as oid, t1.Name as proname, false as proretset, " + //$NON-NLS-1$
- "(SELECT dt.OID FROM ProcedureParams pp, DataTypes dt WHERE pp.ProcedureName = t1.Name AND pp.SchemaName = t1.SchemaName AND pp.Type = 'ResultSet' AND pp.Position = 1 AND dt.Name = pp.DataType) as prorettype, " + //$NON-NLS-1$
- "convert((SELECT count(*) FROM ProcedureParams pp WHERE pp.ProcedureName = t1.Name AND pp.SchemaName = t1.SchemaName ), short) as pronargs, " + //$NON-NLS-1$
- "null as proargtypes, " + //$NON-NLS-1$
- "null as proargnames, " + //$NON-NLS-1$
- "null as proargmodes, " + //$NON-NLS-1$
- "null as proallargtypes, " + //$NON-NLS-1$
- "(SELECT OID FROM SYS.Schemas WHERE Name = t1.SchemaName) as pronamespace " + //$NON-NLS-1$
- "FROM SYS.Procedures as t1"; //$NON-NLS-1$
+
+ String transformation = "SELECT t1.OID as oid, t1.Name as proname, (SELECT (CASE WHEN count(pp.Type)>0 THEN true else false END) as x FROM ProcedureParams pp WHERE pp.ProcedureName = t1.Name AND pp.SchemaName = t1.SchemaName and pp.Type='ResultSet') as proretset, " + //$NON-NLS-1$
+ "CASE WHEN (SELECT count(dt.oid) FROM ProcedureParams pp, matpg_datatype dt WHERE pp.ProcedureName = t1.Name AND pp.SchemaName = t1.SchemaName AND pp.Type IN ('ReturnValue', 'ResultSet') AND dt.Name = pp.DataType) IS NULL THEN (select oid from pg_type WHERE typname = 'void') WHEN (SELECT count(dt.oid) FROM ProcedureParams pp, matpg_datatype dt WHERE pp.ProcedureName = t1.Name AND pp.SchemaName = t1.SchemaName AND pp.Type = 'ResultSet' AND dt.Name = pp.DataType) IS NOT NULL THEN (select oid from pg_type WHERE typname = 'record') ELSE (SELECT dt.oid FROM ProcedureParams pp, matpg_datatype dt WHERE pp.ProcedureName = t1.Name AND pp.SchemaName = t1.SchemaName AND pp.Type = 'ReturnValue' AND dt.Name = pp.DataType) END as prorettype, " + //$NON-NLS-1$
+ "convert((SELECT count(*) FROM ProcedureParams pp WHERE pp.ProcedureName = t1.Name AND pp.SchemaName = t1.SchemaName AND pp.Type IN ('In', 'InOut')), short) as pronargs, " + //$NON-NLS-1$
+ "(select "+textAggStmt("y.oid","y.type, y.position" )+" FROM ("+paramTable("'ResultSet','ReturnValue', 'Out'")+") as y) as proargtypes, " +//$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ "(select "+textAggStmt("y.name", "y.type, y.position")+" FROM (SELECT pp.Name as name, pp.position as position, pp.Type as type FROM ProcedureParams pp WHERE pp.ProcedureName = t1.Name AND pp.SchemaName = t1.SchemaName AND pp.Type NOT IN ('ReturnValue' )) as y) as proargnames, " + //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ "(select case WHEN count(distinct(y.type)) = 1 THEN null ELSE "+textAggStmt("CASE WHEN (y.type ='In') THEN 'i' WHEN (y.type = 'Out') THEN 'o' WHEN (y.type = 'InOut') THEN 'b' WHEN (y.type = 'ResultSet') THEN 't' END", "y.type,y.position")+" END FROM (SELECT pp.Type as type, pp.Position as position FROM ProcedureParams pp WHERE pp.ProcedureName = t1.Name AND pp.SchemaName = t1.SchemaName AND pp.Type NOT IN ('ReturnValue')) as y) as proargmodes, " + //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ "(select case WHEN count(distinct(y.oid)) = 1 THEN null ELSE "+textAggStmt("y.oid", "y.type, y.position")+" END FROM ("+paramTable("'ReturnValue'")+") as y) as proallargtypes, " + //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ "(SELECT OID FROM SYS.Schemas WHERE Name = t1.SchemaName) as pronamespace " + //$NON-NLS-1$
+ "FROM SYS.Procedures as t1";//$NON-NLS-1$
+
t.setSelectTransformation(transformation);
t.setMaterialized(true);
return t;
}
+
+ private String paramTable(String notIn) {
+ return "SELECT dt.oid as oid, pp.Position as position, pp.Type as type FROM ProcedureParams pp LEFT JOIN matpg_datatype dt ON pp.DataType=dt.Name " + //$NON-NLS-1$
+ "WHERE pp.ProcedureName = t1.Name AND pp.SchemaName = t1.SchemaName AND pp.Type NOT IN ("+notIn+")"; //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+
+ private String textAggStmt(String select, String orderby) {
+ return "array_agg("+select+" ORDER BY "+orderby+")"; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ }
-
// triggers
private Table add_pg_trigger() throws TranslatorException {
Table t = createView("pg_trigger"); //$NON-NLS-1$
@@ -360,44 +384,80 @@
addColumn("typtypmod", DataTypeManager.DefaultDataTypes.INTEGER, t); //$NON-NLS-1$
addColumn("typrelid", DataTypeManager.DefaultDataTypes.INTEGER, t); //$NON-NLS-1$
+ addColumn("typelem", DataTypeManager.DefaultDataTypes.INTEGER, t); //$NON-NLS-1$
String transformation =
- "SELECT 16 as oid, 'boolean' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ "SELECT 16 as oid, 'boolean' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
" union " + //$NON-NLS-1$
- //"SELECT 17 as oid, 'blob' as typname,(SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ //"SELECT 17 as oid, 'blob' as typname,(SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
//" union " + //$NON-NLS-1$
- "SELECT 1043 as oid, 'string' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ "SELECT 1043 as oid, 'string' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
" union " + //$NON-NLS-1$
- "SELECT 25 as oid, 'text' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ "SELECT 25 as oid, 'text' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
" union " + //$NON-NLS-1$
- "SELECT 1042 as oid, 'char' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ "SELECT 1042 as oid, 'char' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
" union " + //$NON-NLS-1$
- "SELECT 21 as oid, 'short' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(2, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ "SELECT 21 as oid, 'short' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(2, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
" union " + //$NON-NLS-1$
- "SELECT 20 as oid, 'long' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(8, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ "SELECT 20 as oid, 'long' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(8, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
" union " + //$NON-NLS-1$
- "SELECT 23 as oid, 'integer' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(4, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ "SELECT 23 as oid, 'integer' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(4, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
" union " + //$NON-NLS-1$
- "SELECT 26 as oid, 'oid' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typname, convert(4, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ "SELECT 26 as oid, 'oid' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typname, convert(4, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
" union " + //$NON-NLS-1$
- "SELECT 700 as oid, 'float' as typname,(SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(4, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ "SELECT 700 as oid, 'float' as typname,(SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(4, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
" union " + //$NON-NLS-1$
- "SELECT 701 as oid, 'double' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(8, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ "SELECT 701 as oid, 'double' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(8, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
" union " + //$NON-NLS-1$
- //"SELECT 1009 as oid, 'clob' as typname,(SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ //"SELECT 1009 as oid, 'clob' as typname,(SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
//" union " + //$NON-NLS-1$
- "SELECT 1082 as oid, 'date' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(4, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ "SELECT 1082 as oid, 'date' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(4, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
" union " + //$NON-NLS-1$
- "SELECT 1083 as oid, 'datetime' as typname,(SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(8, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ "SELECT 1083 as oid, 'datetime' as typname,(SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(8, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
" union " + //$NON-NLS-1$
- "SELECT 1114 as oid, 'timestamp' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(8, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ "SELECT 1114 as oid, 'timestamp' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(8, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
" union " + //$NON-NLS-1$
- "SELECT 1700 as oid, 'decimal' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ "SELECT 1700 as oid, 'decimal' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
" union " + //$NON-NLS-1$
- "SELECT 142 as oid, 'xml' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X" + //$NON-NLS-1$
+ "SELECT 142 as oid, 'xml' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
" union " + //$NON-NLS-1$
- "SELECT 14939 as oid, 'lo' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid FROM (SELECT 1) X"; //$NON-NLS-1$
-
+ "SELECT 14939 as oid, 'lo' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X"+//$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 2278 as oid, 'void' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(4, short) as typlen, convert('p', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 2249 as oid, 'record' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('p', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 0 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 30 as oid, 'oidvector' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 26 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 1000 as oid, '_bool' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 16 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 1002 as oid, '_char' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 18 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 1005 as oid, '_int2' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 21 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 1007 as oid, '_int4' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 23 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 1009 as oid, '_text' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 25 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 1028 as oid, '_oid' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 26 as typelem FROM (SELECT 1) X" + //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 1014 as oid, '_bpchar' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 1042 as typelem FROM (SELECT 1) X"+ //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 1015 as oid, '_varchar' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 1043 as typelem FROM (SELECT 1) X"+ //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 1016 as oid, '_int8' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 20 as typelem FROM (SELECT 1) X"+ //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 1021 as oid, '_float4' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 700 as typelem FROM (SELECT 1) X"+ //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 1022 as oid, '_float8' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 701 as typelem FROM (SELECT 1) X"+ //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 1115 as oid, '_timestamp' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 1114 as typelem FROM (SELECT 1) X"+ //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 1182 as oid, '_date' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 1082 as typelem FROM (SELECT 1) X"+ //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 1183 as oid, '_time' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 1083 as typelem FROM (SELECT 1) X"+ //$NON-NLS-1$
+ " union " + //$NON-NLS-1$
+ "SELECT 2287 as oid, '_record' as typname, (SELECT OID FROM SYS.Schemas where Name = 'SYS') as typnamespace, convert(-1, short) as typlen, convert('b', char) as typtype, 0 as typbasetype, -1 as typtypmod, 0 as typrelid, 2249 as typelem FROM (SELECT 1) X"; //$NON-NLS-1$
t.setSelectTransformation(transformation);
return t;
}
@@ -451,10 +511,11 @@
addColumn("relname", DataTypeManager.DefaultDataTypes.STRING, t); //$NON-NLS-1$
addColumn("nspname", DataTypeManager.DefaultDataTypes.STRING, t); //$NON-NLS-1$
addColumn("autoinc", DataTypeManager.DefaultDataTypes.BOOLEAN, t); //$NON-NLS-1$
+ addColumn("typoid", DataTypeManager.DefaultDataTypes.INTEGER, t); //$NON-NLS-1$
addPrimaryKey("pk_matpg_relatt_names", Arrays.asList("attname", "relname", "nspname"), t); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
addIndex("idx_matpg_relatt_ids", true, Arrays.asList("attrelid", "attnum"), t); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
- String transformation = "select pg_class.oid as attrelid, attnum, attname, relname, nspname, IsAutoIncremented as autoinc " + //$NON-NLS-1$
+ String transformation = "select pg_class.oid as attrelid, attnum, attname, relname, nspname, IsAutoIncremented as autoinc, cast((select p.value from SYS.Properties p where p.name = 'pg_type:oid' and p.uid = SYS.Columns.uid) as integer) as typoid " + //$NON-NLS-1$
"from pg_attribute, pg_class, pg_namespace, SYS.Columns " + //$NON-NLS-1$
"where pg_attribute.attrelid = pg_class.oid and pg_namespace.oid = relnamespace" + //$NON-NLS-1$
" and SchemaName = nspname and TableName = relname and Name = attname"; //$NON-NLS-1$
@@ -462,4 +523,48 @@
t.setMaterialized(true);
return t;
}
+
+ private Table add_matpg_datatype() throws TranslatorException {
+ Table t = createView("matpg_datatype"); //$NON-NLS-1$
+ addColumn("oid", DataTypeManager.DefaultDataTypes.INTEGER, t); //$NON-NLS-1$
+ addColumn("typname", DataTypeManager.DefaultDataTypes.STRING, t); //$NON-NLS-1$
+ addColumn("name", DataTypeManager.DefaultDataTypes.STRING, t); //$NON-NLS-1$
+ addColumn("uid", DataTypeManager.DefaultDataTypes.STRING, t); //$NON-NLS-1$
+ addColumn("typlen", DataTypeManager.DefaultDataTypes.SHORT, t); //$NON-NLS-1$
+
+ addPrimaryKey("matpg_datatype_names", Arrays.asList("oid", "name"), t); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ addIndex("matpg_datatype_ids", true, Arrays.asList("typname", "oid"), t); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ String transformation = "select pt.oid as oid, pt.typname as typname, t.Name name, t.UID, pt.typlen from pg_catalog.pg_type pt JOIN (select (CASE "+//$NON-NLS-1$
+ "WHEN (Name = 'clob' OR Name = 'blob') THEN 'lo' " +//$NON-NLS-1$
+ "WHEN (Name = 'byte' ) THEN 'short' " +//$NON-NLS-1$
+ "WHEN (Name = 'time' ) THEN 'datetime' " + //$NON-NLS-1$
+ "WHEN (Name = 'biginteger' ) THEN 'decimal' " +//$NON-NLS-1$
+ "WHEN (Name = 'bigdecimal' ) THEN 'decimal' " +//$NON-NLS-1$
+ "ELSE Name END) as pg_name, Name, UID from SYS.DataTypes) as t ON t.pg_name = pt.typname"; //$NON-NLS-1$
+ t.setSelectTransformation(transformation);
+ t.setMaterialized(true);
+ return t;
+ }
+
+ private FunctionMethod addHasFunctionPrivilage() throws TranslatorException {
+ FunctionMethod func = addFunction("has_function_privilege"); //$NON-NLS-1$
+
+ ArrayList<FunctionParameter> inParams = new ArrayList<FunctionParameter>();
+ inParams.add(new FunctionParameter("oid", DataTypeManager.DefaultDataTypes.INTEGER, ""));//$NON-NLS-1$ //$NON-NLS-2$
+ inParams.add(new FunctionParameter("permission", DataTypeManager.DefaultDataTypes.STRING, "")); //$NON-NLS-1$ //$NON-NLS-2$
+
+ func.setInputParameters(inParams);
+ func.setOutputParameter(new FunctionParameter("result", DataTypeManager.DefaultDataTypes.BOOLEAN, "")); //$NON-NLS-1$ //$NON-NLS-2$
+
+ func.setInvocationClass(ReturnTrue.class.getName());
+ func.setInvocationMethod("result"); //$NON-NLS-1$
+ func.setPushdown(PushDown.CANNOT_PUSHDOWN);
+ return func;
+ }
+
+ public static class ReturnTrue{
+ public static boolean result(@SuppressWarnings("unused")int oid, @SuppressWarnings("unused") String permission) {
+ return true;
+ }
+ }
}
Modified: trunk/runtime/src/main/java/org/teiid/odbc/ODBCServerRemoteImpl.java
===================================================================
--- trunk/runtime/src/main/java/org/teiid/odbc/ODBCServerRemoteImpl.java 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/runtime/src/main/java/org/teiid/odbc/ODBCServerRemoteImpl.java 2011-04-12 23:20:51 UTC (rev 3084)
@@ -126,15 +126,7 @@
"\\s+on cn.conrelid = ref.confrelid" + //$NON-NLS-1$
"\\s+and cn.contype = 'p'\\)" + //$NON-NLS-1$
"\\s+order by ref.oid, ref.i"); //$NON-NLS-1$
-
- private static Pattern procParametersPattern = Pattern.compile("select proname, proretset, prorettype, pronargs, proargtypes, " + //$NON-NLS-1$
- "nspname, p.oid, atttypid, attname, proargnames, proargmodes, proallargtypes from ((pg_catalog.pg_namespace n inner join " + //$NON-NLS-1$
- "pg_catalog.pg_proc p on p.pronamespace = n.oid) inner join pg_type t on t.oid = p.prorettype) left outer join " + //$NON-NLS-1$
- "pg_attribute a on a.attrelid = t.typrelid and attnum > 0 and not attisdropped " + //$NON-NLS-1$
- "where has_function_privilege(p.oid, 'EXECUTE') and nspname like (E?(?:'[^']*')+) " + //$NON-NLS-1$
- "and proname like (E?(?:'[^']*')+) " + //$NON-NLS-1$
- "order by nspname, proname, p.oid, attnum"); //$NON-NLS-1$
-
+
private static Pattern preparedAutoIncrement = Pattern.compile("select 1 \\s*from pg_catalog.pg_attrdef \\s*where adrelid = \\$1 AND adnum = \\$2 " + //$NON-NLS-1$
"\\s*and pg_catalog.pg_get_expr\\(adbin, adrelid\\) \\s*like '%nextval\\(%'", Pattern.CASE_INSENSITIVE); //$NON-NLS-1$
Modified: trunk/runtime/src/main/java/org/teiid/transport/PgBackendProtocol.java
===================================================================
--- trunk/runtime/src/main/java/org/teiid/transport/PgBackendProtocol.java 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/runtime/src/main/java/org/teiid/transport/PgBackendProtocol.java 2011-04-12 23:20:51 UTC (rev 3084)
@@ -35,9 +35,10 @@
import java.sql.ResultSet;
import java.sql.ResultSetMetaData;
import java.sql.SQLException;
-import java.sql.SQLXML;
import java.sql.Statement;
import java.sql.Types;
+import java.util.ArrayList;
+import java.util.List;
import java.util.Properties;
import org.jboss.netty.buffer.ChannelBuffer;
@@ -51,6 +52,7 @@
import org.teiid.core.util.ObjectConverterUtil;
import org.teiid.core.util.ReaderInputStream;
import org.teiid.core.util.ReflectionHelper;
+import org.teiid.deployers.PgCatalogMetadataStore;
import org.teiid.jdbc.ResultSetImpl;
import org.teiid.jdbc.TeiidSQLException;
import org.teiid.logging.LogConstants;
@@ -67,16 +69,14 @@
public class PgBackendProtocol implements ChannelDownstreamHandler, ODBCClientRemote {
private final class ResultsWorkItem implements Runnable {
- private final int[] types;
+ private final List<PgColInfo> cols;
private final String sql;
- private final int columns;
private final ResultSetImpl rs;
- private ResultsWorkItem(int[] types, String sql, int columns,
+ private ResultsWorkItem(List<PgColInfo> cols, String sql,
ResultSetImpl rs) {
- this.types = types;
+ this.cols = cols;
this.sql = sql;
- this.columns = columns;
this.rs = rs;
}
@@ -115,7 +115,7 @@
boolean processNext = true;
try {
if (future.get()) {
- sendDataRow(rs, columns, types);
+ sendDataRow(rs, cols);
} else {
sendCommandComplete(sql, 0);
processNext = false;
@@ -145,7 +145,12 @@
private static final int PG_TYPE_FLOAT4 = 700;
private static final int PG_TYPE_FLOAT8 = 701;
private static final int PG_TYPE_UNKNOWN = 705;
- //private static final int PG_TYPE_TEXTARRAY = 1009;
+
+ private static final int PG_TYPE_OIDVECTOR = PgCatalogMetadataStore.PG_TYPE_OIDVECTOR;
+ private static final int PG_TYPE_OIDARRAY = PgCatalogMetadataStore.PG_TYPE_OIDARRAY;
+ private static final int PG_TYPE_CHARARRAY = PgCatalogMetadataStore.PG_TYPE_CHARARRAY;
+ private static final int PG_TYPE_TEXTARRAY = PgCatalogMetadataStore.PG_TYPE_TEXTARRAY;
+
private static final int PG_TYPE_DATE = 1082;
private static final int PG_TYPE_TIME = 1083;
private static final int PG_TYPE_TIMESTAMP_NO_TMZONE = 1114;
@@ -313,7 +318,8 @@
public void sendResultSetDescription(ResultSetMetaData metaData, Statement stmt) {
try {
try {
- sendRowDescription(metaData, stmt);
+ List<PgColInfo> cols = getPgColInfo(metaData, stmt);
+ sendRowDescription(cols);
} catch (SQLException e) {
sendErrorResponse(e);
}
@@ -331,16 +337,12 @@
sendErrorResponse(new IllegalStateException("Pending results have not been sent")); //$NON-NLS-1$
}
try {
+ ResultSetMetaData meta = rs.getMetaData();
+ List<PgColInfo> cols = getPgColInfo(meta, rs.getStatement());
if (describeRows) {
- ResultSetMetaData meta = rs.getMetaData();
- sendRowDescription(meta, rs.getStatement());
+ sendRowDescription(cols);
}
- final int columns = rs.getMetaData().getColumnCount();
- final int[] types = new int[columns];
- for(int i = 0; i < columns; i++) {
- types[i] = rs.getMetaData().getColumnType(i+1);
- }
- Runnable r = new ResultsWorkItem(types, sql, columns, rs);
+ Runnable r = new ResultsWorkItem(cols, sql, rs);
r.run();
} catch (SQLException e) {
sendErrorResponse(e);
@@ -429,11 +431,11 @@
sendMessage();
}
- private void sendDataRow(ResultSet rs, int columns, int[] types) throws SQLException, IOException {
+ private void sendDataRow(ResultSet rs, List<PgColInfo> cols) throws SQLException, IOException {
startMessage('D');
- writeShort(columns);
- for (int i = 0; i < columns; i++) {
- byte[] bytes = getContent(rs, types[i], i+1);
+ writeShort(cols.size());
+ for (int i = 0; i < cols.size(); i++) {
+ byte[] bytes = getContent(rs, cols.get(i), i+1);
if (bytes == null) {
writeInt(-1);
} else {
@@ -444,49 +446,35 @@
sendMessage();
}
- private byte[] getContent(ResultSet rs, int type, int column) throws SQLException, TeiidSQLException, IOException {
+ private byte[] getContent(ResultSet rs, PgColInfo col, int column) throws SQLException, TeiidSQLException, IOException {
byte[] bytes = null;
- switch (type) {
- case Types.BIT:
- case Types.BOOLEAN:
- case Types.VARCHAR:
- case Types.CHAR:
- case Types.SMALLINT:
- case Types.INTEGER:
- case Types.BIGINT:
- case Types.NUMERIC:
- case Types.DECIMAL:
- case Types.FLOAT:
- case Types.REAL:
- case Types.DOUBLE:
- case Types.TIME:
- case Types.DATE:
- case Types.TIMESTAMP:
+ switch (col.type) {
+ case PG_TYPE_BOOL:
+ case PG_TYPE_BPCHAR:
+ case PG_TYPE_DATE:
+ case PG_TYPE_FLOAT4:
+ case PG_TYPE_FLOAT8:
+ case PG_TYPE_INT2:
+ case PG_TYPE_INT4:
+ case PG_TYPE_INT8:
+ case PG_TYPE_NUMERIC:
+ case PG_TYPE_TIME:
+ case PG_TYPE_TIMESTAMP_NO_TMZONE:
+ case PG_TYPE_VARCHAR:
String value = rs.getString(column);
if (value != null) {
bytes = value.getBytes(this.encoding);
}
break;
- case Types.LONGVARCHAR:
- case Types.CLOB:
+ case PG_TYPE_TEXT:
Clob clob = rs.getClob(column);
if (clob != null) {
bytes = ObjectConverterUtil.convertToByteArray(new ReaderInputStream(clob.getCharacterStream(), this.encoding), this.maxLobSize);
}
break;
- case Types.SQLXML:
- SQLXML xml = rs.getSQLXML(column);
- if (xml != null) {
- bytes = ObjectConverterUtil.convertToByteArray(new ReaderInputStream(xml.getCharacterStream(), this.encoding), this.maxLobSize);
- }
- break;
-
- case Types.BINARY:
- case Types.VARBINARY:
- case Types.LONGVARBINARY:
- case Types.BLOB:
+ case PG_TYPE_BYTEA:
Blob blob = rs.getBlob(column);
if (blob != null) {
try {
@@ -496,12 +484,75 @@
}
}
break;
+
+ case PG_TYPE_CHARARRAY:
+ case PG_TYPE_TEXTARRAY:
+ case PG_TYPE_OIDARRAY:
+ {
+ Object[] obj = (Object[])rs.getObject(column);
+ if (obj != null) {
+ StringBuilder sb = new StringBuilder();
+ sb.append("{");
+ boolean first = true;
+ for (Object o:obj) {
+ if (!first) {
+ sb.append(",");
+ }
+ else {
+ first = false;
+ }
+ if (col.type == PG_TYPE_TEXTARRAY) {
+ escapeQuote(sb, o.toString());
+ }
+ else {
+ sb.append(o.toString());
+ }
+ }
+ sb.append("}");
+ bytes = sb.toString().getBytes(this.encoding);
+ }
+ }
+ break;
+
+ case PG_TYPE_OIDVECTOR:
+ {
+ Object[] obj = (Object[])rs.getObject(column);
+ if (obj != null) {
+ StringBuilder sb = new StringBuilder();
+ boolean first = true;
+ for (Object o:obj) {
+ if (!first) {
+ sb.append(" ");
+ }
+ else {
+ first = false;
+ }
+ sb.append(o);
+ }
+ bytes = sb.toString().getBytes(this.encoding);
+ }
+ }
+ break;
+
default:
throw new TeiidSQLException("unknown datatype failed to convert");
}
return bytes;
}
+ public static void escapeQuote(StringBuilder sb, String s) {
+ sb.append('"');
+ for (int i = 0; i < s.length(); i++) {
+ char c = s.charAt(i);
+ if (c == '"' || c == '\\') {
+ sb.append('\\');
+ }
+
+ sb.append(c);
+ }
+ sb.append('"');
+ }
+
@Override
public void sslDenied() {
ChannelBuffer buffer = ChannelBuffers.directBuffer(1);
@@ -529,57 +580,74 @@
startMessage('n');
sendMessage();
}
+
+ private static class PgColInfo {
+ String name;
+ int reloid;
+ short attnum;
+ int type;
+ int precision;
+ }
- private void sendRowDescription(ResultSetMetaData meta, Statement stmt) throws SQLException, IOException {
- if (meta == null) {
- sendNoData();
- } else {
- int columns = meta.getColumnCount();
- startMessage('T');
- writeShort(columns);
- for (int i = 1; i < columns + 1; i++) {
- writeString(meta.getColumnName(i).toLowerCase());
- int type = meta.getColumnType(i);
- type = convertType(type);
- int precision = meta.getColumnDisplaySize(i);
- String name = meta.getColumnName(i);
- String table = meta.getTableName(i);
- String schema = meta.getSchemaName(i);
- int reloid = 0;
- short attnum = 0;
- if (schema != null) {
- PreparedStatement ps = null;
- try {
- ps = stmt.getConnection().prepareStatement("select attrelid, attnum from matpg_relatt where attname = ? and relname = ? and nspname = ?");
- ps.setString(1, name);
- ps.setString(2, table);
- ps.setString(3, schema);
- ResultSet rs = ps.executeQuery();
- if (rs.next()) {
- reloid = rs.getInt(1);
- attnum = rs.getShort(2);
+ private void sendRowDescription(List<PgColInfo> cols) throws IOException {
+ startMessage('T');
+ writeShort(cols.size());
+ for (PgColInfo info : cols) {
+ writeString(info.name);
+ // rel ID
+ writeInt(info.reloid);
+ // attribute number of the column
+ writeShort(info.attnum);
+ // data type
+ writeInt(info.type);
+ // pg_type.typlen
+ writeShort(getTypeSize(info.type, info.precision));
+ // pg_attribute.atttypmod
+ writeInt(-1);
+ // text
+ writeShort(0);
+ }
+ sendMessage();
+ }
+
+ private List<PgColInfo> getPgColInfo(ResultSetMetaData meta, Statement stmt)
+ throws SQLException {
+ int columns = meta.getColumnCount();
+ ArrayList<PgColInfo> result = new ArrayList<PgColInfo>(columns);
+ for (int i = 1; i < columns + 1; i++) {
+ PgColInfo info = new PgColInfo();
+ info.name = meta.getColumnName(i).toLowerCase();
+ info.type = meta.getColumnType(i);
+ info.type = convertType(info.type);
+ info.precision = meta.getColumnDisplaySize(i);
+ String name = meta.getColumnName(i);
+ String table = meta.getTableName(i);
+ String schema = meta.getSchemaName(i);
+ if (schema != null) {
+ PreparedStatement ps = null;
+ try {
+ ps = stmt.getConnection().prepareStatement("select attrelid, attnum, typoid from matpg_relatt where attname = ? and relname = ? and nspname = ?");
+ ps.setString(1, name);
+ ps.setString(2, table);
+ ps.setString(3, schema);
+ ResultSet rs = ps.executeQuery();
+ if (rs.next()) {
+ info.reloid = rs.getInt(1);
+ info.attnum = rs.getShort(2);
+ int specificType = rs.getInt(3);
+ if (!rs.wasNull()) {
+ info.type = specificType;
}
- } finally {
- if (ps != null) {
- ps.close();
- }
}
+ } finally {
+ if (ps != null) {
+ ps.close();
+ }
}
- // rel ID
- writeInt(reloid);
- // attribute number of the column
- writeShort(attnum);
- // data type
- writeInt(type);
- // pg_type.typlen
- writeShort(getTypeSize(type, precision));
- // pg_attribute.atttypmod
- writeInt(-1);
- // text
- writeShort(0);
}
- sendMessage();
+ result.add(info);
}
+ return result;
}
private int getTypeSize(int pgType, int precision) {
Added: trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestODBCProceduresSchema.java
===================================================================
--- trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestODBCProceduresSchema.java (rev 0)
+++ trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestODBCProceduresSchema.java 2011-04-12 23:20:51 UTC (rev 3084)
@@ -0,0 +1,123 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * See the COPYRIGHT.txt file distributed with this work for information
+ * regarding copyright ownership. Some portions may be licensed
+ * to Red Hat, Inc. under one or more contributor license agreements.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA.
+ */
+package org.teiid.systemmodel;
+
+import static org.junit.Assert.*;
+
+
+import org.junit.Before;
+import org.junit.Test;
+import org.teiid.core.util.UnitTestUtil;
+import org.teiid.jdbc.AbstractMMQueryTestCase;
+import org.teiid.jdbc.FakeServer;
+
+@SuppressWarnings("nls")
+public class TestODBCProceduresSchema extends AbstractMMQueryTestCase {
+ private static final String VDB = "bqt"; //$NON-NLS-1$
+
+ public TestODBCProceduresSchema() {
+ // this is needed because the result files are generated
+ // with another tool which uses tab as delimiter
+ super.DELIMITER = "\t"; //$NON-NLS-1$
+ }
+
+ @Before public void setUp() throws Exception {
+ FakeServer server = new FakeServer();
+ server.deployVDB(VDB, UnitTestUtil.getTestDataPath() + "/bqt.vdb");
+ this.internalConnection = server.createConnection("jdbc:teiid:" + VDB); //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ @Test public void test_Pg_Proc_alltypes() throws Exception {
+ execute("select oid, proname, proretset,prorettype, pronargs, proargtypes, proargnames, proargmodes, proallargtypes, pronamespace FROM pg_proc where proname='bigProcedure'"); //$NON-NLS-1$
+ if (this.internalResultSet.next()) {
+ assertEquals(1, this.internalResultSet.getInt(1)); //oid
+ assertEquals("bigProcedure", this.internalResultSet.getString(2)); //proname
+ assertEquals(true, this.internalResultSet.getBoolean(3)); //proretset
+ assertEquals(2249, this.internalResultSet.getInt(4)); //prorettype
+ assertEquals(14, this.internalResultSet.getInt(5)); //pronargs
+ assertArrayEquals(new Object[] {1700,1043,700,20,701,21,1082,1083,1114,16,1043,21,1700,1700}, (Object[])this.internalResultSet.getObject(6)); //proargtypes
+ assertArrayEquals(new Object[] {"intNum","stringNum","floatNum","longNum","doubleNum","byteNum","dateValue","timeValue","timestampValue","booValue","charValue","shortNum","bigIntNum","bigdecimalNum","col","col2"}, (Object[])this.internalResultSet.getObject(7)); //proargnames
+ assertArrayEquals(new Object[] {"i","i","i","i","i","i","i","i","i","i","i","i","i","i","t","t"}, (Object[])this.internalResultSet.getObject(8)); //proargmodes
+ assertArrayEquals(new Object[] {1700,1043,700,20,701,21,1082,1083,1114,16,1043,21,1700,1700,1043,1700}, (Object[])this.internalResultSet.getObject(9)); //proallargtypes
+ assertEquals(1, this.internalResultSet.getInt(10)); //pronamespace
+ }
+ else {
+ fail("no results");
+ }
+ }
+
+ @Test public void test_Pg_Proc_void() throws Exception {
+ execute("select oid, proname, proretset,prorettype, pronargs, proargtypes, proargnames, proargmodes, proallargtypes, pronamespace FROM pg_proc where proname='VoidProcedure'"); //$NON-NLS-1$
+ if (this.internalResultSet.next()) {
+ assertEquals(4, this.internalResultSet.getInt(1)); //oid
+ assertEquals("VoidProcedure", this.internalResultSet.getString(2)); //proname
+ assertEquals(false, this.internalResultSet.getBoolean(3)); //proretset
+ assertEquals(2278, this.internalResultSet.getInt(4)); //prorettype
+ assertEquals(2, this.internalResultSet.getInt(5)); //pronargs
+ assertArrayEquals(new Object[] {1700,1043}, (Object[])this.internalResultSet.getObject(6)); //proargtypes
+ assertArrayEquals(new Object[] {"intNum","stringNum"}, (Object[])this.internalResultSet.getObject(7)); //proargnames
+ assertArrayEquals(null, (Object[])this.internalResultSet.getObject(8)); //proargmodes
+ assertArrayEquals(new Object[] {1700,1043}, (Object[])this.internalResultSet.getObject(9)); //proallargtypes
+ assertEquals(1, this.internalResultSet.getInt(10)); //pronamespace
+ }
+ else {
+ fail("no results");
+ }
+ }
+
+ @Test public void test_Pg_Proc_with_return() throws Exception {
+ execute("select oid, proname, proretset,prorettype, pronargs, proargtypes, proargnames, proargmodes, proallargtypes, pronamespace FROM pg_proc where proname='ProcedureWithReturn'"); //$NON-NLS-1$
+ if (this.internalResultSet.next()) {
+ assertEquals(3, this.internalResultSet.getInt(1)); //oid
+ assertEquals("ProcedureWithReturn", this.internalResultSet.getString(2)); //proname
+ assertEquals(false, this.internalResultSet.getBoolean(3)); //proretset
+ assertEquals(20, this.internalResultSet.getInt(4)); //prorettype
+ assertEquals(3, this.internalResultSet.getInt(5)); //pronargs
+ assertArrayEquals(new Object[] {1700,1043,700}, (Object[])this.internalResultSet.getObject(6)); //proargtypes
+ assertArrayEquals(new Object[] {"intNum","stringNum","floatNum"}, (Object[])this.internalResultSet.getObject(7)); //proargnames
+ assertArrayEquals(null, (Object[])this.internalResultSet.getObject(8)); //proargmodes
+ assertArrayEquals(new Object[] {1700,1043,700}, (Object[])this.internalResultSet.getObject(9)); //proallargtypes
+ assertEquals(1, this.internalResultSet.getInt(10)); //pronamespace
+ }
+ else {
+ fail("no results");
+ }
+ }
+ @Test public void test_Pg_Proc_with_return_table() throws Exception {
+ execute("select oid, proname, proretset,prorettype, pronargs, proargtypes, proargnames, proargmodes, proallargtypes, pronamespace FROM pg_proc where proname='ProcedureReturnTable'"); //$NON-NLS-1$
+ if (this.internalResultSet.next()) {
+ assertEquals(2, this.internalResultSet.getInt(1)); //oid
+ assertEquals("ProcedureReturnTable", this.internalResultSet.getString(2)); //proname
+ assertEquals(true, this.internalResultSet.getBoolean(3)); //proretset
+ assertEquals(2249, this.internalResultSet.getInt(4)); //prorettype
+ assertEquals(2, this.internalResultSet.getInt(5)); //pronargs
+ assertArrayEquals(new Object[] {1700,1700}, (Object[])this.internalResultSet.getObject(6)); //proargtypes
+ assertArrayEquals(new Object[] {"intNum","bigDecimalNum","col1","col2"}, (Object[])this.internalResultSet.getObject(7)); //proargnames
+ assertArrayEquals(new Object[] {"i","i","t","t"}, (Object[])this.internalResultSet.getObject(8)); //proargmodes
+ assertArrayEquals(new Object[] {1700,1700,1043,1114}, (Object[])this.internalResultSet.getObject(9)); //proallargtypes
+ assertEquals(1, this.internalResultSet.getInt(10)); //pronamespace
+ }
+ else {
+ fail("no results");
+ }
+ }
+}
Property changes on: trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestODBCProceduresSchema.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Modified: trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestODBCSchema.java
===================================================================
--- trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestODBCSchema.java 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestODBCSchema.java 2011-04-12 23:20:51 UTC (rev 3084)
@@ -55,11 +55,6 @@
TestMMDatabaseMetaData.compareResultSet(this.internalResultSet);
}
- @Test public void test_PG_PROC() throws Exception {
- execute("select * FROM pg_proc"); //$NON-NLS-1$
- TestMMDatabaseMetaData.compareResultSet(this.internalResultSet);
- }
-
@Test public void test_PG_TRIGGER() throws Exception {
execute("select * FROM pg_trigger"); //$NON-NLS-1$
TestMMDatabaseMetaData.compareResultSet(this.internalResultSet);
Modified: trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestSystemVirtualModel.java
===================================================================
--- trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestSystemVirtualModel.java 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestSystemVirtualModel.java 2011-04-12 23:20:51 UTC (rev 3084)
@@ -84,7 +84,13 @@
}
@Test public void testProperties() {
- String[] expected = { "Name[string] Value[string] UID[string] OID[integer]", }; //$NON-NLS-1$
+ String[] expected = { "Name[string] Value[string] UID[string] OID[integer]",
+ "pg_type:oid 30 mmuid:ffa4ac73-b549-470e-931f-dc36330cb8c4 1",
+ "pg_type:oid 1009 mmuid:d9f36bdc-7b25-4af0-b9f5-a96aac6d3094 2",
+ "pg_type:oid 1002 mmuid:bcbed548-176c-4116-a5d6-7638cb0206e1 3",
+ "pg_type:oid 1028 mmuid:a385751f-a31a-4d5d-9197-3fbd390b0251 4"
+
+ }; //$NON-NLS-1$
executeAndAssertResults("select* from SYS.Properties", expected); //$NON-NLS-1$
}
@@ -133,6 +139,10 @@
"PK_SUPPLIER_PARTS null", //$NON-NLS-1$
"idx_matpg_relatt_ids null",
"idx_matpg_relatt_ids null",
+ "matpg_datatype_ids null",
+ "matpg_datatype_ids null",
+ "matpg_datatype_names null",
+ "matpg_datatype_names null",
"pk_matpg_relatt_names null",
"pk_matpg_relatt_names null",
"pk_matpg_relatt_names null",
Modified: trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestVirtualDocWithVirtualProc.java
===================================================================
--- trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestVirtualDocWithVirtualProc.java 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/java/org/teiid/systemmodel/TestVirtualDocWithVirtualProc.java 2011-04-12 23:20:51 UTC (rev 3084)
@@ -89,7 +89,11 @@
String[] expected ={
"Name[string] Value[string] UID[string]", //$NON-NLS-1$
"NugentXAttribute Nuuuuuge22222 mmuuid:4789b280-841c-1f15-9526-ebd0cace03e1", //$NON-NLS-1$
- "NugentYAttribute Nuuuuuge44444 mmuuid:4789b280-841c-1f15-9526-ebd0cace03e1" //$NON-NLS-1$
+ "NugentYAttribute Nuuuuuge44444 mmuuid:4789b280-841c-1f15-9526-ebd0cace03e1",
+ "pg_type:oid 30 mmuid:ffa4ac73-b549-470e-931f-dc36330cb8c4" ,
+ "pg_type:oid 1009 mmuid:d9f36bdc-7b25-4af0-b9f5-a96aac6d3094" ,
+ "pg_type:oid 1002 mmuid:bcbed548-176c-4116-a5d6-7638cb0206e1",
+ "pg_type:oid 1028 mmuid:a385751f-a31a-4d5d-9197-3fbd390b0251"
};
executeAndAssertResults(sql, expected);
}
Modified: trunk/test-integration/common/src/test/java/org/teiid/transport/TestODBCSocketTransport.java
===================================================================
--- trunk/test-integration/common/src/test/java/org/teiid/transport/TestODBCSocketTransport.java 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/java/org/teiid/transport/TestODBCSocketTransport.java 2011-04-12 23:20:51 UTC (rev 3084)
@@ -139,4 +139,17 @@
assertTrue(rs.next());
assertEquals("\n\thello pg", rs.getString(1));
}
+
+ @Test public void testPgProc() throws Exception {
+ Statement stmt = conn.createStatement();
+ ResultSet rs = stmt.executeQuery("select * from pg_proc");
+ rs.next();
+ assertEquals("oid", rs.getArray("proargtypes").getBaseTypeName());
+ }
+
+ @Test public void testPgProcedure() throws Exception {
+ Statement stmt = conn.createStatement();
+ ResultSet rs = stmt.executeQuery("select has_function_privilege(100, 'foo')");
+ rs.next();
+ }
}
Modified: trunk/test-integration/common/src/test/resources/TestCase3473/testGetTables.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestCase3473/testGetTables.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestCase3473/testGetTables.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -13,6 +13,7 @@
test SYS VirtualDatabases SYSTEM TABLE <null> <null> <null> <null> <null> <null> true
test SYSADMIN MatViews SYSTEM TABLE <null> <null> <null> <null> <null> <null> true
test SYSADMIN VDBResources SYSTEM TABLE <null> <null> <null> <null> <null> <null> true
+test pg_catalog matpg_datatype SYSTEM TABLE <null> <null> <null> <null> <null> <null> false
test pg_catalog matpg_relatt SYSTEM TABLE <null> <null> <null> <null> <null> <null> false
test pg_catalog pg_am SYSTEM TABLE <null> <null> <null> <null> <null> <null> false
test pg_catalog pg_attrdef SYSTEM TABLE <null> <null> <null> <null> <null> <null> false
@@ -28,7 +29,7 @@
test test all_databases TABLE <null> <null> <null> <null> <null> <null> false
test test all_models TABLE <null> <null> <null> <null> <null> <null> false
test test all_tables TABLE <null> <null> <null> <null> <null> <null> false
-Row Count : 28
+Row Count : 29
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
VDBName 12 test java.lang.String TABLE_CAT string SYS Tables 255 255 0 false true false true 1 false true true true
SchemaName 12 test java.lang.String TABLE_SCHEM string SYS Tables 255 255 0 false true false true 1 false true true true
Modified: trunk/test-integration/common/src/test/resources/TestMMDatabaseMetaData/testGetColumns.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestMMDatabaseMetaData/testGetColumns.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestMMDatabaseMetaData/testGetColumns.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -757,12 +757,18 @@
QT_Ora9DS XQTRecursiveDoc groupDocument.MappingClasses.supervisor ID 2 biginteger 19 <null> 0 0 1 <null> <null> <null> <null> 0 1 YES <null> <null> <null> !
<null> NO
QT_Ora9DS XQTRecursiveDoc groupDocument.MappingClasses.supervisor code 2 biginteger 19 <null> 0 0 1 <null> <null> <null> <null> 0 2 YES <null> <null> <null> !
<null> NO
QT_Ora9DS XQTRecursiveDoc groupDocument.MappingClasses.supervisor groupID 2 biginteger 19 <null> 0 0 1 <null> <null> <null> <null> 0 3 YES <null> <null> <null> !
<null> NO
+QT_Ora9DS pg_catalog matpg_datatype oid 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 1 <null> <null> <null> !
<null> NO
+QT_Ora9DS pg_catalog matpg_datatype typname 12 string 4000 <null> 0 0 2 <null> <null> <null> <null> 0 2 <null> <null> <null> !
<null> NO
+QT_Ora9DS pg_catalog matpg_datatype name 12 string 4000 <null> 0 0 2 <null> <null> <null> <null> 0 3 <null> <null> <null> !
<null> NO
+QT_Ora9DS pg_catalog matpg_datatype uid 12 string 4000 <null> 0 0 2 <null> <null> <null> <null> 0 4 <null> <null> <null> !
<null> NO
+QT_Ora9DS pg_catalog matpg_datatype typlen 5 short 5 <null> 0 0 2 <null> <null> <null> <null> 0 5 <null> <null> <null> !
<null> NO
QT_Ora9DS pg_catalog matpg_relatt attrelid 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 1 <null> <null> <null> !
<null> NO
QT_Ora9DS pg_catalog matpg_relatt attnum 5 short 5 <null> 0 0 2 <null> <null> <null> <null> 0 2 <null> <null> <null> !
<null> NO
QT_Ora9DS pg_catalog matpg_relatt attname 12 string 4000 <null> 0 0 2 <null> <null> <null> <null> 0 3 <null> <null> <null> !
<null> NO
QT_Ora9DS pg_catalog matpg_relatt relname 12 string 4000 <null> 0 0 2 <null> <null> <null> <null> 0 4 <null> <null> <null> !
<null> NO
QT_Ora9DS pg_catalog matpg_relatt nspname 12 string 4000 <null> 0 0 2 <null> <null> <null> <null> 0 5 <null> <null> <null> !
<null> NO
QT_Ora9DS pg_catalog matpg_relatt autoinc -7 boolean 1 <null> 0 0 2 <null> <null> <null> <null> 0 6 <null> <null> <null> !
<null> NO
+QT_Ora9DS pg_catalog matpg_relatt typoid 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 7 <null> <null> <null> !
<null> NO
QT_Ora9DS XQTDoc mixedContentTestDocument mixedContentTest.wrapper3.key3.data3 12 string 4000 <null> 0 0 1 <null> <null> <null> <null> 0 0 YES <null> <null> <null> !
<null> NO
QT_Ora9DS XQTDoc mixedContentTestDocument mixedContentTest.wrapper3.key3 12 string 4000 <null> 0 0 1 <null> <null> <null> <null> 0 0 YES <null> <null> <null> !
<null> NO
QT_Ora9DS XQTDoc mixedContentTestDocument mixedContentTest.wrapper3 12 string 4000 <null> 0 0 1 <null> <null> <null> <null> 0 0 YES <null> <null> <null> !
<null> NO
@@ -851,6 +857,7 @@
QT_Ora9DS pg_catalog pg_type typbasetype 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 6 <null> <null> <null> !
<null> NO
QT_Ora9DS pg_catalog pg_type typtypmod 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 7 <null> <null> <null> !
<null> NO
QT_Ora9DS pg_catalog pg_type typrelid 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 8 <null> <null> <null> !
<null> NO
+QT_Ora9DS pg_catalog pg_type typelem 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 9 <null> <null> <null> !
<null> NO
QT_Ora9DS pg_catalog pg_user oid 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 1 <null> <null> <null> !
<null> NO
QT_Ora9DS pg_catalog pg_user usename 12 string 4000 <null> 0 0 2 <null> <null> <null> <null> 0 2 <null> <null> <null> !
<null> NO
QT_Ora9DS pg_catalog pg_user usecreatedb -7 boolean 1 <null> 0 0 2 <null> <null> <null> <null> 0 3 <null> <null> <null> !
<null> NO
@@ -1074,7 +1081,7 @@
QT_Ora9DS XQT xqtFullData BigIntegerValue 2 biginteger 19 <null> 0 10 1 <null> <null> <null> <null> 28 15 YES <null> <null> <null> !
<null> NO
QT_Ora9DS XQT xqtFullData BigDecimalValue 2 bigdecimal 20 <null> 0 10 1 <null> <null> <null> <null> 126 16 YES <null> <null> <null> !
<null> NO
QT_Ora9DS XQT xqtFullData ObjectValue 2000 object 2048 <null> 0 10 1 <null> <null> <null> <null> 2048 17 YES <null> <null> <null> !
<null> NO
-Row Count : 1074
+Row Count : 1081
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
VDBName 12 QT_Ora9DS java.lang.String TABLE_CAT string SYS Columns 255 255 0 false false false false 0 true true false false
SchemaName 12 QT_Ora9DS java.lang.String TABLE_SCHEM string SYS Columns 255 255 0 false true false true 1 false true true true
Modified: trunk/test-integration/common/src/test/resources/TestMMDatabaseMetaData/testGetTables.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestMMDatabaseMetaData/testGetTables.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestMMDatabaseMetaData/testGetTables.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -31,6 +31,7 @@
QT_Ora9DS SYS VirtualDatabases SYSTEM TABLE <null> <null> <null> <null> <null> <null> true
QT_Ora9DS SYSADMIN MatViews SYSTEM TABLE <null> <null> <null> <null> <null> <null> true
QT_Ora9DS SYSADMIN VDBResources SYSTEM TABLE <null> <null> <null> <null> <null> <null> true
+QT_Ora9DS pg_catalog matpg_datatype SYSTEM TABLE <null> <null> <null> <null> <null> <null> false
QT_Ora9DS pg_catalog matpg_relatt SYSTEM TABLE <null> <null> <null> <null> <null> <null> false
QT_Ora9DS pg_catalog pg_am SYSTEM TABLE <null> <null> <null> <null> <null> <null> false
QT_Ora9DS pg_catalog pg_attrdef SYSTEM TABLE <null> <null> <null> <null> <null> <null> false
@@ -135,7 +136,7 @@
QT_Ora9DS XQTNestedDoc testOptimizableTempTable.MappingClasses.moveToRootTempTable XMLSTAGINGTABLE <null> <null> <null> <null> <null> <null> false
QT_Ora9DS XQTNestedDoc testRootTempTable.MappingClasses.TemporaryTable1 XMLSTAGINGTABLE <null> <null> <null> <null> <null> <null> false
QT_Ora9DS XQTRecursiveDoc testSimpleTempTable.MappingClasses.TemporaryTable1 XMLSTAGINGTABLE <null> <null> <null> <null> <null> <null> false
-Row Count : 135
+Row Count : 136
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
VDBName 12 QT_Ora9DS java.lang.String TABLE_CAT string SYS Tables 255 255 0 false true false true 1 false true true true
SchemaName 12 QT_Ora9DS java.lang.String TABLE_SCHEM string SYS Tables 255 255 0 false true false true 1 false true true true
Modified: trunk/test-integration/common/src/test/resources/TestMMDatabaseMetaData/testGetTables_allTables.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestMMDatabaseMetaData/testGetTables_allTables.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestMMDatabaseMetaData/testGetTables_allTables.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -31,6 +31,7 @@
QT_Ora9DS SYS VirtualDatabases SYSTEM TABLE <null> <null> <null> <null> <null> <null> true
QT_Ora9DS SYSADMIN MatViews SYSTEM TABLE <null> <null> <null> <null> <null> <null> true
QT_Ora9DS SYSADMIN VDBResources SYSTEM TABLE <null> <null> <null> <null> <null> <null> true
+QT_Ora9DS pg_catalog matpg_datatype SYSTEM TABLE <null> <null> <null> <null> <null> <null> false
QT_Ora9DS pg_catalog matpg_relatt SYSTEM TABLE <null> <null> <null> <null> <null> <null> false
QT_Ora9DS pg_catalog pg_am SYSTEM TABLE <null> <null> <null> <null> <null> <null> false
QT_Ora9DS pg_catalog pg_attrdef SYSTEM TABLE <null> <null> <null> <null> <null> <null> false
@@ -135,7 +136,7 @@
QT_Ora9DS XQTNestedDoc testOptimizableTempTable.MappingClasses.moveToRootTempTable XMLSTAGINGTABLE <null> <null> <null> <null> <null> <null> false
QT_Ora9DS XQTNestedDoc testRootTempTable.MappingClasses.TemporaryTable1 XMLSTAGINGTABLE <null> <null> <null> <null> <null> <null> false
QT_Ora9DS XQTRecursiveDoc testSimpleTempTable.MappingClasses.TemporaryTable1 XMLSTAGINGTABLE <null> <null> <null> <null> <null> <null> false
-Row Count : 135
+Row Count : 136
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
VDBName 12 QT_Ora9DS java.lang.String TABLE_CAT string SYS Tables 255 255 0 false true false true 1 false true true true
SchemaName 12 QT_Ora9DS java.lang.String TABLE_SCHEM string SYS Tables 255 255 0 false true false true 1 false true true true
Modified: trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_ATTRIBUTE.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_ATTRIBUTE.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_ATTRIBUTE.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -190,59 +190,66 @@
188 22 typbasetype 23 4 6 0 false false false
189 22 typtypmod 23 4 7 0 false false false
190 22 typrelid 23 4 8 0 false false false
-191 23 oid 23 4 1 0 false false false
-192 23 indexrelid 23 4 2 0 false false false
-193 23 indrelid 23 4 3 0 false false false
-194 23 indisclustered 16 1 4 0 false false false
-195 23 indisunique 16 1 5 0 false false false
-196 23 indisprimary 16 1 6 0 false false false
-197 23 indexprs 1043 -1 7 0 false false false
-198 23 indkey 1043 -1 8 0 false false false
-199 24 oid 23 4 1 0 false false false
-200 24 amname 1043 -1 2 0 false false false
-201 25 oid 23 4 1 0 false false false
-202 25 proname 1043 -1 2 0 false false false
-203 25 proretset 16 1 3 0 false false false
-204 25 prorettype 23 4 4 0 false false false
-205 25 pronargs 21 2 5 0 false false false
-206 25 proargtypes <null> <null> 6 0 false false false
-207 25 proargnames <null> <null> 7 0 false false false
-208 25 proargmodes <null> <null> 8 0 false false false
-209 25 proallargtypes <null> <null> 9 0 false false false
-210 25 pronamespace 23 4 10 0 false false false
-211 26 oid 23 4 1 0 false false false
-212 26 tgconstrrelid 23 4 2 0 false false false
-213 26 tgfoid 23 4 3 0 false false false
-214 26 tgargs 23 4 4 0 false false false
-215 26 tgnargs 23 4 5 0 false false false
-216 26 tgdeferrable 16 1 6 0 false false false
-217 26 tginitdeferred 16 1 7 0 false false false
-218 26 tgconstrname 1043 -1 8 0 false false false
-219 26 tgrelid 23 4 9 0 false false false
-220 27 adrelid 23 4 1 0 false false false
-221 27 adnum 23 4 2 0 false false false
-222 27 adbin 1043 -1 3 0 false false false
-223 27 adsrc 1043 -1 4 0 false false false
-224 28 oid 23 4 1 0 false false false
-225 28 datname 1043 -1 2 0 false false false
-226 28 encoding 23 4 3 0 false false false
-227 28 datlastsysoid 23 4 4 0 false false false
-228 28 datallowconn 1042 1 5 0 false false false
-229 28 datconfig <null> <null> 6 0 false false false
-230 28 datacl <null> <null> 7 0 false false false
-231 28 datdba 23 4 8 0 false false false
-232 28 dattablespace 23 4 9 0 false false false
-233 29 oid 23 4 1 0 false false false
-234 29 usename 1043 -1 2 0 false false false
-235 29 usecreatedb 16 1 3 0 false false false
-236 29 usesuper 16 1 4 0 false false false
-237 30 attrelid 23 4 1 0 false false false
-238 30 attnum 21 2 2 0 false false false
-239 30 attname 1043 -1 3 0 false false false
-240 30 relname 1043 -1 4 0 false false false
-241 30 nspname 1043 -1 5 0 false false false
-242 30 autoinc 16 1 6 0 false false false
-Row Count : 242
+191 22 typelem 23 4 9 0 false false false
+192 23 oid 23 4 1 0 false false false
+193 23 indexrelid 23 4 2 0 false false false
+194 23 indrelid 23 4 3 0 false false false
+195 23 indisclustered 16 1 4 0 false false false
+196 23 indisunique 16 1 5 0 false false false
+197 23 indisprimary 16 1 6 0 false false false
+198 23 indexprs 1043 -1 7 0 false false false
+199 23 indkey 1043 -1 8 0 false false false
+200 24 oid 23 4 1 0 false false false
+201 24 amname 1043 -1 2 0 false false false
+202 25 oid 23 4 1 0 false false false
+203 25 proname 1043 -1 2 0 false false false
+204 25 proretset 16 1 3 0 false false false
+205 25 prorettype 23 4 4 0 false false false
+206 25 pronargs 21 2 5 0 false false false
+207 25 proargtypes <null> <null> 6 0 false false false
+208 25 proargnames <null> <null> 7 0 false false false
+209 25 proargmodes <null> <null> 8 0 false false false
+210 25 proallargtypes <null> <null> 9 0 false false false
+211 25 pronamespace 23 4 10 0 false false false
+212 26 oid 23 4 1 0 false false false
+213 26 tgconstrrelid 23 4 2 0 false false false
+214 26 tgfoid 23 4 3 0 false false false
+215 26 tgargs 23 4 4 0 false false false
+216 26 tgnargs 23 4 5 0 false false false
+217 26 tgdeferrable 16 1 6 0 false false false
+218 26 tginitdeferred 16 1 7 0 false false false
+219 26 tgconstrname 1043 -1 8 0 false false false
+220 26 tgrelid 23 4 9 0 false false false
+221 27 adrelid 23 4 1 0 false false false
+222 27 adnum 23 4 2 0 false false false
+223 27 adbin 1043 -1 3 0 false false false
+224 27 adsrc 1043 -1 4 0 false false false
+225 28 oid 23 4 1 0 false false false
+226 28 datname 1043 -1 2 0 false false false
+227 28 encoding 23 4 3 0 false false false
+228 28 datlastsysoid 23 4 4 0 false false false
+229 28 datallowconn 1042 1 5 0 false false false
+230 28 datconfig <null> <null> 6 0 false false false
+231 28 datacl <null> <null> 7 0 false false false
+232 28 datdba 23 4 8 0 false false false
+233 28 dattablespace 23 4 9 0 false false false
+234 29 oid 23 4 1 0 false false false
+235 29 usename 1043 -1 2 0 false false false
+236 29 usecreatedb 16 1 3 0 false false false
+237 29 usesuper 16 1 4 0 false false false
+238 30 attrelid 23 4 1 0 false false false
+239 30 attnum 21 2 2 0 false false false
+240 30 attname 1043 -1 3 0 false false false
+241 30 relname 1043 -1 4 0 false false false
+242 30 nspname 1043 -1 5 0 false false false
+243 30 autoinc 16 1 6 0 false false false
+244 30 typoid 23 4 7 0 false false false
+245 31 oid 23 4 1 0 false false false
+246 31 typname 1043 -1 2 0 false false false
+247 31 name 1043 -1 3 0 false false false
+248 31 uid 1043 -1 4 0 false false false
+249 31 typlen 21 2 5 0 false false false
+Row Count : 249
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
oid 4 PartsSupplier java.lang.Integer oid integer pg_catalog pg_attribute 11 10 0 false false false false 2 true true false false
attrelid 4 PartsSupplier java.lang.Integer attrelid integer pg_catalog pg_attribute 11 10 0 false false false false 2 true true false false
Modified: trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_CLASS.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_CLASS.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_CLASS.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -30,7 +30,8 @@
28 pg_database 4 v 0 0.0 0 false false
29 pg_user 4 v 0 0.0 0 false false
30 matpg_relatt 4 v 0 0.0 0 false false
-Row Count : 30
+31 matpg_datatype 4 v 0 0.0 0 false false
+Row Count : 31
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
oid 4 PartsSupplier java.lang.Integer oid integer pg_catalog pg_class 11 10 0 false false false false 2 true true false false
relname 12 PartsSupplier java.lang.String relname string pg_catalog pg_class 4000 4000 0 false false false false 2 true true false false
Modified: trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_INDEX.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_INDEX.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_INDEX.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -18,7 +18,11 @@
16 16 30 false false true 0
17 17 30 false false false 0
18 18 30 false false false 0
-Row Count : 18
+19 19 31 false false true 0
+20 20 31 false false true 0
+21 21 31 false false false 0
+22 22 31 false false false 0
+Row Count : 22
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
oid 4 PartsSupplier java.lang.Integer oid integer pg_catalog pg_index 11 10 0 false false false false 2 true true false false
indexrelid 4 PartsSupplier java.lang.Integer indexrelid integer pg_catalog pg_index 11 10 0 false false false false 2 true true false false
Deleted: trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_PROC.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_PROC.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_PROC.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -1,17 +0,0 @@
-integer string boolean integer short object object object object integer
-oid proname proretset prorettype pronargs proargtypes proargnames proargmodes proallargtypes pronamespace
-1 refreshMatViewRow false <null> 3 <null> <null> <null> <null> 2
-2 refreshMatView false <null> 3 <null> <null> <null> <null> 2
-3 getXMLSchemas false <null> 2 <null> <null> <null> <null> 3
-Row Count : 3
-getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
-oid 4 PartsSupplier java.lang.Integer oid integer pg_catalog pg_proc 11 10 0 false false false false 2 true true false false
-proname 12 PartsSupplier java.lang.String proname string pg_catalog pg_proc 4000 4000 0 false false false false 2 true true false false
-proretset -7 PartsSupplier java.lang.Boolean proretset boolean pg_catalog pg_proc 5 1 0 false false false false 2 true true false false
-prorettype 4 PartsSupplier java.lang.Integer prorettype integer pg_catalog pg_proc 11 10 0 false false false false 2 true true false false
-pronargs 5 PartsSupplier java.lang.Short pronargs short pg_catalog pg_proc 6 5 0 false false false false 2 true true false false
-proargtypes 2000 PartsSupplier java.lang.Object proargtypes object pg_catalog pg_proc 2147483647 2147483647 0 false false false false 2 true true false false
-proargnames 2000 PartsSupplier java.lang.Object proargnames object pg_catalog pg_proc 2147483647 2147483647 0 false false false false 2 true true false false
-proargmodes 2000 PartsSupplier java.lang.Object proargmodes object pg_catalog pg_proc 2147483647 2147483647 0 false false false false 2 true true false false
-proallargtypes 2000 PartsSupplier java.lang.Object proallargtypes object pg_catalog pg_proc 2147483647 2147483647 0 false false false false 2 true true false false
-pronamespace 4 PartsSupplier java.lang.Integer pronamespace integer pg_catalog pg_proc 11 10 0 false false false false 2 true true false false
Modified: trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_TYPE.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_TYPE.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestODBCSchema/test_PG_TYPE.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -1,22 +1,40 @@
-integer string integer short char integer integer integer
-oid typname typnamespace typlen typtype typbasetype typtypmod typrelid
-16 boolean 3 1 b 0 -1 0
-20 long 3 8 b 0 -1 0
-21 short 3 2 b 0 -1 0
-23 integer 3 4 b 0 -1 0
-25 text 3 -1 b 0 -1 0
-26 oid 3 4 b 0 -1 0
-142 xml 3 -1 b 0 -1 0
-700 float 3 4 b 0 -1 0
-701 double 3 8 b 0 -1 0
-1042 char 3 1 b 0 -1 0
-1043 string 3 -1 b 0 -1 0
-1082 date 3 4 b 0 -1 0
-1083 datetime 3 8 b 0 -1 0
-1114 timestamp 3 8 b 0 -1 0
-1700 decimal 3 -1 b 0 -1 0
-14939 lo 3 -1 b 0 -1 0
-Row Count : 16
+integer string integer short char integer integer integer integer
+oid typname typnamespace typlen typtype typbasetype typtypmod typrelid typelem
+16 boolean 3 1 b 0 -1 0 0
+20 long 3 8 b 0 -1 0 0
+21 short 3 2 b 0 -1 0 0
+23 integer 3 4 b 0 -1 0 0
+25 text 3 -1 b 0 -1 0 0
+26 oid 3 4 b 0 -1 0 0
+30 oidvector 3 -1 b 0 -1 0 26
+142 xml 3 -1 b 0 -1 0 0
+700 float 3 4 b 0 -1 0 0
+701 double 3 8 b 0 -1 0 0
+1000 _bool 3 -1 b 0 -1 0 16
+1002 _char 3 -1 b 0 -1 0 18
+1005 _int2 3 -1 b 0 -1 0 21
+1007 _int4 3 -1 b 0 -1 0 23
+1009 _text 3 -1 b 0 -1 0 25
+1014 _bpchar 3 -1 b 0 -1 0 1042
+1015 _varchar 3 -1 b 0 -1 0 1043
+1016 _int8 3 -1 b 0 -1 0 20
+1021 _float4 3 -1 b 0 -1 0 700
+1022 _float8 3 -1 b 0 -1 0 701
+1028 _oid 3 -1 b 0 -1 0 26
+1042 char 3 1 b 0 -1 0 0
+1043 string 3 -1 b 0 -1 0 0
+1082 date 3 4 b 0 -1 0 0
+1083 datetime 3 8 b 0 -1 0 0
+1114 timestamp 3 8 b 0 -1 0 0
+1115 _timestamp 3 -1 b 0 -1 0 1114
+1182 _date 3 -1 b 0 -1 0 1082
+1183 _time 3 -1 b 0 -1 0 1083
+1700 decimal 3 -1 b 0 -1 0 0
+2249 record 3 -1 p 0 -1 0 0
+2278 void 3 4 p 0 -1 0 0
+2287 _record 3 -1 b 0 -1 0 2249
+14939 lo 3 -1 b 0 -1 0 0
+Row Count : 34
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
oid 4 PartsSupplier java.lang.Integer oid integer pg_catalog pg_type 11 10 0 false false false false 2 true true false false
typname 12 PartsSupplier java.lang.String typname string pg_catalog pg_type 4000 4000 0 false false false false 2 true true false false
@@ -26,3 +44,4 @@
typbasetype 4 PartsSupplier java.lang.Integer typbasetype integer pg_catalog pg_type 11 10 0 false false false false 2 true true false false
typtypmod 4 PartsSupplier java.lang.Integer typtypmod integer pg_catalog pg_type 11 10 0 false false false false 2 true true false false
typrelid 4 PartsSupplier java.lang.Integer typrelid integer pg_catalog pg_type 11 10 0 false false false false 2 true true false false
+typelem 4 PartsSupplier java.lang.Integer typelem integer pg_catalog pg_type 11 10 0 false false false false 2 true true false false
Modified: trunk/test-integration/common/src/test/resources/TestODBCSocketTransport/testSelect.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestODBCSocketTransport/testSelect.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestODBCSocketTransport/testSelect.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -18,19 +18,20 @@
parts SYS Tables Table <null> true false mmuuid:8551b3bd-11cc-4049-9bcf-fe91a0eb7ba7 0 <null> true false 17
parts SYSADMIN VDBResources Table <null> true false mmuuid:1785804d-beaf-4831-9531-e59164fedd49 0 <null> true false 7
parts SYS VirtualDatabases Table <null> true false mmuuid:47297c72-d621-4f4e-af4e-74060ac5f489 0 <null> true false 18
-parts pg_catalog matpg_relatt Table <null> false false mmuid:9bfddc66-af75-4366-8eac-b9fef3421219 0 <null> true true 30
-parts pg_catalog pg_am Table <null> false false mmuid:1462b28e-0bab-436f-9654-013821506337 0 <null> true false 24
-parts pg_catalog pg_attrdef Table <null> false false mmuid:71091853-c65e-46a9-9947-aa024f806e2d 0 <null> true false 27
+parts pg_catalog matpg_datatype Table <null> false false mmuid:17448311-6679-4dfd-aeb6-4aabbd894729 0 <null> true true 31
+parts pg_catalog matpg_relatt Table <null> false false mmuid:8c0714d6-1c72-40b4-8528-3b2c63059107 0 <null> true true 30
+parts pg_catalog pg_am Table <null> false false mmuid:f6517a63-8c14-4b73-a18d-afaa5dfb35d9 0 <null> true false 24
+parts pg_catalog pg_attrdef Table <null> false false mmuid:76a7dd05-9a7d-4243-b561-f3056500dcaf 0 <null> true false 27
parts pg_catalog pg_attribute Table <null> false false mmuid:fa463d98-365f-489a-a707-025193cb51eb 0 <null> true true 21
parts pg_catalog pg_class Table <null> false false mmuid:7e21f2e6-06e3-4bca-9b01-72ea47821560 0 <null> true true 20
-parts pg_catalog pg_database Table <null> false false mmuid:492dd834-907f-429b-aa6e-958ad65204c6 0 <null> true false 28
-parts pg_catalog pg_index Table <null> false false mmuid:22ac431d-e6e6-4eef-9d74-b31795424e97 0 <null> true true 23
+parts pg_catalog pg_database Table <null> false false mmuid:382f9fc9-8c96-4df7-ab5d-04dfb47ee142 0 <null> true false 28
+parts pg_catalog pg_index Table <null> false false mmuid:09daed8d-b0b8-4552-a261-2b6c775b46b0 0 <null> true true 23
parts pg_catalog pg_namespace Table <null> false false mmuid:6609866a-3d7b-4f4b-95fe-ebfac769d699 0 <null> true false 19
-parts pg_catalog pg_proc Table <null> false false mmuid:da4b747e-7d87-403a-8309-2cdf1399031b 0 <null> true true 25
-parts pg_catalog pg_trigger Table <null> false false mmuid:9569efdb-21b2-4b4f-a2db-e7406267b8ed 0 <null> true false 26
+parts pg_catalog pg_proc Table <null> false false mmuid:f20c9489-10ca-4596-8a37-24218b67f764 0 <null> true true 25
+parts pg_catalog pg_trigger Table <null> false false mmuid:2b75f0b1-7475-4ed5-9da3-d37a8a25f26a 0 <null> true false 26
parts pg_catalog pg_type Table <null> false false mmuid:9462e3f8-cd3c-414f-a570-f6f33c40e36a 0 <null> true false 22
-parts pg_catalog pg_user Table <null> false false mmuid:28d034eb-6f39-402f-b642-9c9560e57247 0 <null> true false 29
-Row Count : 30
+parts pg_catalog pg_user Table <null> false false mmuid:e63613cb-01ee-4b37-8b91-99d1aac4dfcb 0 <null> true false 29
+Row Count : 31
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
vdbname 12 java.lang.String vdbname varchar 2147483647 0 0 false true false false 1 false true false true
schemaname 12 java.lang.String schemaname varchar 2147483647 0 0 false true false false 1 false true false true
Modified: trunk/test-integration/common/src/test/resources/TestPartsDatabaseMetadata/testColumns.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestPartsDatabaseMetadata/testColumns.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestPartsDatabaseMetadata/testColumns.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -161,12 +161,18 @@
PartsSupplier SYSADMIN VDBResources contents 2004 blob 2147483647 <null> 0 10 1 <null> <null> <null> <null> 0 2 YES <null> <null> <null> !
<null> NO
PartsSupplier SYS VirtualDatabases Name 12 string 255 <null> 0 10 0 <null> <null> <null> <null> 255 1 NO <null> <null> <null> !
<null> NO
PartsSupplier SYS VirtualDatabases Version 12 string 50 <null> 0 10 0 <null> <null> <null> <null> 50 2 NO <null> <null> <null> !
<null> NO
+PartsSupplier pg_catalog matpg_datatype oid 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 1 <null> <null> <null> !
<null> NO
+PartsSupplier pg_catalog matpg_datatype typname 12 string 4000 <null> 0 0 2 <null> <null> <null> <null> 0 2 <null> <null> <null> !
<null> NO
+PartsSupplier pg_catalog matpg_datatype name 12 string 4000 <null> 0 0 2 <null> <null> <null> <null> 0 3 <null> <null> <null> !
<null> NO
+PartsSupplier pg_catalog matpg_datatype uid 12 string 4000 <null> 0 0 2 <null> <null> <null> <null> 0 4 <null> <null> <null> !
<null> NO
+PartsSupplier pg_catalog matpg_datatype typlen 5 short 5 <null> 0 0 2 <null> <null> <null> <null> 0 5 <null> <null> <null> !
<null> NO
PartsSupplier pg_catalog matpg_relatt attrelid 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 1 <null> <null> <null> !
<null> NO
PartsSupplier pg_catalog matpg_relatt attnum 5 short 5 <null> 0 0 2 <null> <null> <null> <null> 0 2 <null> <null> <null> !
<null> NO
PartsSupplier pg_catalog matpg_relatt attname 12 string 4000 <null> 0 0 2 <null> <null> <null> <null> 0 3 <null> <null> <null> !
<null> NO
PartsSupplier pg_catalog matpg_relatt relname 12 string 4000 <null> 0 0 2 <null> <null> <null> <null> 0 4 <null> <null> <null> !
<null> NO
PartsSupplier pg_catalog matpg_relatt nspname 12 string 4000 <null> 0 0 2 <null> <null> <null> <null> 0 5 <null> <null> <null> !
<null> NO
PartsSupplier pg_catalog matpg_relatt autoinc -7 boolean 1 <null> 0 0 2 <null> <null> <null> <null> 0 6 <null> <null> <null> !
<null> NO
+PartsSupplier pg_catalog matpg_relatt typoid 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 7 <null> <null> <null> !
<null> NO
PartsSupplier pg_catalog pg_am oid 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 1 <null> <null> <null> !
<null> NO
PartsSupplier pg_catalog pg_am amname 12 string 4000 <null> 0 0 2 <null> <null> <null> <null> 0 2 <null> <null> <null> !
<null> NO
PartsSupplier pg_catalog pg_attrdef adrelid 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 1 <null> <null> <null> !
<null> NO
@@ -238,11 +244,12 @@
PartsSupplier pg_catalog pg_type typbasetype 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 6 <null> <null> <null> !
<null> NO
PartsSupplier pg_catalog pg_type typtypmod 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 7 <null> <null> <null> !
<null> NO
PartsSupplier pg_catalog pg_type typrelid 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 8 <null> <null> <null> !
<null> NO
+PartsSupplier pg_catalog pg_type typelem 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 9 <null> <null> <null> !
<null> NO
PartsSupplier pg_catalog pg_user oid 4 integer 10 <null> 0 0 2 <null> <null> <null> <null> 0 1 <null> <null> <null> !
<null> NO
PartsSupplier pg_catalog pg_user usename 12 string 4000 <null> 0 0 2 <null> <null> <null> <null> 0 2 <null> <null> <null> !
<null> NO
PartsSupplier pg_catalog pg_user usecreatedb -7 boolean 1 <null> 0 0 2 <null> <null> <null> <null> 0 3 <null> <null> <null> !
<null> NO
PartsSupplier pg_catalog pg_user usesuper -7 boolean 1 <null> 0 0 2 <null> <null> <null> <null> 0 4 <null> <null> <null> !
<null> NO
-Row Count : 242
+Row Count : 249
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
VDBName 12 PartsSupplier java.lang.String TABLE_CAT string SYS Columns 255 255 0 false false false false 0 true true false false
SchemaName 12 PartsSupplier java.lang.String TABLE_SCHEM string SYS Columns 255 255 0 false true false true 1 false true true true
Modified: trunk/test-integration/common/src/test/resources/TestPartsDatabaseMetadata/testIndexInfo.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestPartsDatabaseMetadata/testIndexInfo.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestPartsDatabaseMetadata/testIndexInfo.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -2,7 +2,9 @@
VDBName SchemaName TableName NON_UNIQUE INDEX_QUALIFIER KeyName TYPE ORDINAL_POSITION Name ASC_OR_DESC CARDINALITY PAGES FILTER_CONDITION
PartsSupplier pg_catalog matpg_relatt true <null> idx_matpg_relatt_ids 0 1 attrelid <null> 0 1 <null>
PartsSupplier pg_catalog matpg_relatt true <null> idx_matpg_relatt_ids 0 2 attnum <null> 0 1 <null>
-Row Count : 2
+PartsSupplier pg_catalog matpg_datatype true <null> matpg_datatype_ids 0 1 typname <null> 0 1 <null>
+PartsSupplier pg_catalog matpg_datatype true <null> matpg_datatype_ids 0 2 oid <null> 0 1 <null>
+Row Count : 4
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
VDBName 12 PartsSupplier java.lang.String TABLE_CAT string SYS KeyColumns 255 255 0 false false false false 0 true true false false
SchemaName 12 PartsSupplier java.lang.String TABLE_SCHEM string SYS KeyColumns 255 255 0 false true false true 1 false true true true
Modified: trunk/test-integration/common/src/test/resources/TestPartsDatabaseMetadata/testPrimaryKeys.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestPartsDatabaseMetadata/testPrimaryKeys.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestPartsDatabaseMetadata/testPrimaryKeys.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -7,13 +7,15 @@
PartsSupplier PartsSupplier PARTSSUPPLIER.SUPPLIER_PARTS SUPPLIER_ID 1 PK_SUPPLIER_PARTS
PartsSupplier PartsSupplier PARTSSUPPLIER.SUPPLIER SUPPLIER_ID 1 PK_SUPPLIER
PartsSupplier pg_catalog matpg_relatt attname 1 pk_matpg_relatt_names
+PartsSupplier pg_catalog matpg_datatype name 2 matpg_datatype_names
PartsSupplier pg_catalog matpg_relatt nspname 3 pk_matpg_relatt_names
PartsSupplier pg_catalog pg_class oid 1 pk_pg_class
PartsSupplier pg_catalog pg_attribute oid 1 pk_pg_attr
PartsSupplier pg_catalog pg_index oid 1 pk_pg_index
PartsSupplier pg_catalog pg_proc oid 1 pk_pg_proc
+PartsSupplier pg_catalog matpg_datatype oid 1 matpg_datatype_names
PartsSupplier pg_catalog matpg_relatt relname 2 pk_matpg_relatt_names
-Row Count : 13
+Row Count : 15
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
VDBName 12 PartsSupplier java.lang.String TABLE_CAT string SYS KeyColumns 255 255 0 false false false false 0 true true false false
SchemaName 12 PartsSupplier java.lang.String TABLE_SCHEM string SYS KeyColumns 255 255 0 false true false true 1 false true true true
Modified: trunk/test-integration/common/src/test/resources/TestPartsDatabaseMetadata/testTables.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestPartsDatabaseMetadata/testTables.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestPartsDatabaseMetadata/testTables.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -13,6 +13,7 @@
PartsSupplier SYS VirtualDatabases SYSTEM TABLE <null> <null> <null> <null> <null> <null> true
PartsSupplier SYSADMIN MatViews SYSTEM TABLE <null> <null> <null> <null> <null> <null> true
PartsSupplier SYSADMIN VDBResources SYSTEM TABLE <null> <null> <null> <null> <null> <null> true
+PartsSupplier pg_catalog matpg_datatype SYSTEM TABLE <null> <null> <null> <null> <null> <null> false
PartsSupplier pg_catalog matpg_relatt SYSTEM TABLE <null> <null> <null> <null> <null> <null> false
PartsSupplier pg_catalog pg_am SYSTEM TABLE <null> <null> <null> <null> <null> <null> false
PartsSupplier pg_catalog pg_attrdef SYSTEM TABLE <null> <null> <null> <null> <null> <null> false
@@ -30,7 +31,7 @@
PartsSupplier PartsSupplier PARTSSUPPLIER.STATUS TABLE <null> <null> <null> <null> <null> <null> true
PartsSupplier PartsSupplier PARTSSUPPLIER.SUPPLIER TABLE <null> <null> <null> <null> <null> <null> true
PartsSupplier PartsSupplier PARTSSUPPLIER.SUPPLIER_PARTS TABLE <null> <null> <null> <null> <null> <null> true
-Row Count : 30
+Row Count : 31
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
VDBName 12 PartsSupplier java.lang.String TABLE_CAT string SYS Tables 255 255 0 false true false true 1 false true true true
SchemaName 12 PartsSupplier java.lang.String TABLE_SCHEM string SYS Tables 255 255 0 false true false true 1 false true true true
Modified: trunk/test-integration/common/src/test/resources/TestSystemVirtualModel/testColumns.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestSystemVirtualModel/testColumns.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestSystemVirtualModel/testColumns.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -159,90 +159,97 @@
PartsSupplier SYSADMIN MatViews Valid 6 <null> boolean 0 0 false true false true true false false Nullable <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 10 mmuuid:13098912-bce2-4842-9ea9-b162fcd7383e !
<null> 23
PartsSupplier SYS Properties Value 2 <null> string 0 255 true true false true true false false No Nulls <null> <null> Searchable <null> <null> java.lang.String 255 255 10 mmuuid:c917257d-06b7-41dd-a6cb-44c0ff0f897e !
<null> 123
PartsSupplier SYS VirtualDatabases Version 2 <null> string 0 50 true true false true false false false No Nulls <null> <null> Searchable <null> <null> java.lang.String 50 50 10 mmuuid:c876d749-a512-4810-9910-3034ca524c45 !
<null> 161
-PartsSupplier pg_catalog pg_attrdef adbin 3 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:e9b278d4-49af-442f-9a5a-b699fe3b102b !
<null> 222
-PartsSupplier pg_catalog pg_attrdef adnum 2 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:4589389f-4abd-42a6-818f-ff1f2a085dfb !
<null> 221
-PartsSupplier pg_catalog pg_attrdef adrelid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:76a7dd05-9a7d-4243-b561-f3056500dcaf !
<null> 220
-PartsSupplier pg_catalog pg_attrdef adsrc 4 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:e22c521a-e208-4181-9dbd-89f5de7014b9 !
<null> 223
-PartsSupplier pg_catalog pg_am amname 2 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:3c67619c-7d8f-4378-b7e9-84a0451ea5e5 !
<null> 200
+PartsSupplier pg_catalog pg_attrdef adbin 3 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:e22c521a-e208-4181-9dbd-89f5de7014b9 !
<null> 223
+PartsSupplier pg_catalog pg_attrdef adnum 2 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:e9b278d4-49af-442f-9a5a-b699fe3b102b !
<null> 222
+PartsSupplier pg_catalog pg_attrdef adrelid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:4589389f-4abd-42a6-818f-ff1f2a085dfb !
<null> 221
+PartsSupplier pg_catalog pg_attrdef adsrc 4 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:492dd834-907f-429b-aa6e-958ad65204c6 !
<null> 224
+PartsSupplier pg_catalog pg_am amname 2 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:da4b747e-7d87-403a-8309-2cdf1399031b !
<null> 201
PartsSupplier pg_catalog pg_attribute atthasdef 10 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:5868e549-4bbe-479e-bc7e-632c05cc2329 !
<null> 182
PartsSupplier pg_catalog pg_attribute attisdropped 9 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:7beb42a9-dfe6-43de-98b6-7e8948b1a666 !
<null> 181
PartsSupplier pg_catalog pg_attribute attlen 5 <null> short 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Short 0 0 0 mmuid:d1214249-95cd-426f-b8f6-4bf68c0504c7 !
<null> 177
PartsSupplier pg_catalog pg_attribute attname 3 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:6064d149-4102-4c2d-9132-582342f25e90 !
<null> 175
-PartsSupplier pg_catalog matpg_relatt attname 3 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:0b0894ba-e1ea-4eaf-bcd2-ea9ebd05e47d !
<null> 239
+PartsSupplier pg_catalog matpg_relatt attname 3 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:5cfb2b62-a912-4bfb-bf4f-51e107fe210c !
<null> 240
PartsSupplier pg_catalog pg_attribute attnotnull 8 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:91ce8bde-8570-4867-be17-80acfa9275a6 !
<null> 180
PartsSupplier pg_catalog pg_attribute attnum 6 <null> short 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Short 0 0 0 mmuid:141fd911-f2dd-4edd-8f08-ad8a67ffd0fb !
<null> 178
-PartsSupplier pg_catalog matpg_relatt attnum 2 <null> short 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Short 0 0 0 mmuid:5c7bf056-ecc5-41ea-a122-7a4b1de9908a !
<null> 238
+PartsSupplier pg_catalog matpg_relatt attnum 2 <null> short 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Short 0 0 0 mmuid:0b0894ba-e1ea-4eaf-bcd2-ea9ebd05e47d !
<null> 239
PartsSupplier pg_catalog pg_attribute attrelid 2 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:3be6b5de-2287-4279-93f3-4f5064799118 !
<null> 174
-PartsSupplier pg_catalog matpg_relatt attrelid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:8c0714d6-1c72-40b4-8528-3b2c63059107 !
<null> 237
+PartsSupplier pg_catalog matpg_relatt attrelid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:5c7bf056-ecc5-41ea-a122-7a4b1de9908a !
<null> 238
PartsSupplier pg_catalog pg_attribute atttypid 4 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:99782493-1cce-4e14-9c1b-4de7ce50e2c8 !
<null> 176
PartsSupplier pg_catalog pg_attribute atttypmod 7 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:2e2bae3c-ab93-49f5-b96c-7a7b9d66782d !
<null> 179
-PartsSupplier pg_catalog matpg_relatt autoinc 6 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:f1998229-2c1a-47b7-8f46-9dda81446db6 !
<null> 242
+PartsSupplier pg_catalog matpg_relatt autoinc 6 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:23454408-0347-40d2-a3f9-3faa664fb5e9 !
<null> 243
PartsSupplier SYSADMIN VDBResources contents 2 <null> blob 0 0 false true false true true false false Nullable <null> <null> Searchable <null> <null> org.teiid.core.types.BlobType 0 0 10 mmuuid:f9421669-3564-451d-9293-96c1e5e72c4f !
<null> 28
-PartsSupplier pg_catalog pg_database datacl 7 <null> object 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Object 0 0 0 mmuid:4b5beb14-03a0-4652-9d6f-5f8cc74d470c !
<null> 230
-PartsSupplier pg_catalog pg_database datallowconn 5 <null> char 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Character 0 0 0 mmuid:c2bdf40c-ec58-439c-a403-7adf604ceadd !
<null> 228
-PartsSupplier pg_catalog pg_database datconfig 6 <null> object 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Object 0 0 0 mmuid:5c9d54b2-433f-443a-85ce-821f42ed109e !
<null> 229
-PartsSupplier pg_catalog pg_database datdba 8 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:8b993c11-de2b-48bc-beb1-3e44c46811b4 !
<null> 231
-PartsSupplier pg_catalog pg_database datlastsysoid 4 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:3b621b25-171c-405b-8bf9-635cf93f2273 !
<null> 227
-PartsSupplier pg_catalog pg_database datname 2 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:689cde3b-a631-4f25-94b4-ff2ffe022b0f !
<null> 225
-PartsSupplier pg_catalog pg_database dattablespace 9 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:36db343d-e99a-427c-a4e2-763a720ce4a4 !
<null> 232
-PartsSupplier pg_catalog pg_database encoding 3 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:1aedd02c-5801-41e7-accd-da1f257c26e8 !
<null> 226
-PartsSupplier pg_catalog pg_index indexprs 7 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:9ea3b6d2-b27b-4bb1-a99d-b703c3308384 !
<null> 197
-PartsSupplier pg_catalog pg_index indexrelid 2 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:83ae2247-7eec-459f-b037-ffd3cdca0627 !
<null> 192
-PartsSupplier pg_catalog pg_index indisclustered 4 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:16998907-e1dd-447e-898d-780994d30619 !
<null> 194
-PartsSupplier pg_catalog pg_index indisprimary 6 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:a52c714d-dfe9-406c-906b-fadd53ac4e98 !
<null> 196
-PartsSupplier pg_catalog pg_index indisunique 5 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:9f873e0f-903d-4c9d-8c37-1073b5ec4c67 !
<null> 195
-PartsSupplier pg_catalog pg_index indkey 8 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:1e6dbecd-9a2d-4aef-afbe-665de7acb9d6 !
<null> 198
-PartsSupplier pg_catalog pg_index indrelid 3 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:8709e084-48df-417d-b3f8-f4e9b7d8802b !
<null> 193
+PartsSupplier pg_catalog pg_database datacl 7 <null> object 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Object 0 0 0 mmuid:8b993c11-de2b-48bc-beb1-3e44c46811b4 !
<null> 231
+PartsSupplier pg_catalog pg_database datallowconn 5 <null> char 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Character 0 0 0 mmuid:5c9d54b2-433f-443a-85ce-821f42ed109e !
<null> 229
+PartsSupplier pg_catalog pg_database datconfig 6 <null> object 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Object 0 0 0 mmuid:4b5beb14-03a0-4652-9d6f-5f8cc74d470c !
<null> 230
+PartsSupplier pg_catalog pg_database datdba 8 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:36db343d-e99a-427c-a4e2-763a720ce4a4 !
<null> 232
+PartsSupplier pg_catalog pg_database datlastsysoid 4 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:c2bdf40c-ec58-439c-a403-7adf604ceadd !
<null> 228
+PartsSupplier pg_catalog pg_database datname 2 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:1aedd02c-5801-41e7-accd-da1f257c26e8 !
<null> 226
+PartsSupplier pg_catalog pg_database dattablespace 9 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:28d034eb-6f39-402f-b642-9c9560e57247 !
<null> 233
+PartsSupplier pg_catalog pg_database encoding 3 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:3b621b25-171c-405b-8bf9-635cf93f2273 !
<null> 227
+PartsSupplier pg_catalog pg_index indexprs 7 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:1e6dbecd-9a2d-4aef-afbe-665de7acb9d6 !
<null> 198
+PartsSupplier pg_catalog pg_index indexrelid 2 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:8709e084-48df-417d-b3f8-f4e9b7d8802b !
<null> 193
+PartsSupplier pg_catalog pg_index indisclustered 4 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:9f873e0f-903d-4c9d-8c37-1073b5ec4c67 !
<null> 195
+PartsSupplier pg_catalog pg_index indisprimary 6 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:9ea3b6d2-b27b-4bb1-a99d-b703c3308384 !
<null> 197
+PartsSupplier pg_catalog pg_index indisunique 5 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:a52c714d-dfe9-406c-906b-fadd53ac4e98 !
<null> 196
+PartsSupplier pg_catalog pg_index indkey 8 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:347ec08c-6b41-41d0-8475-031ce7d99ac0 !
<null> 199
+PartsSupplier pg_catalog pg_index indrelid 3 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:16998907-e1dd-447e-898d-780994d30619 !
<null> 194
+PartsSupplier pg_catalog matpg_datatype name 3 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:b4e04928-9a59-4718-a7f1-3a60bcae7449 !
<null> 247
PartsSupplier pg_catalog pg_namespace nspname 2 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:0e513513-b35a-48be-975d-5dbed6ace7e9 !
<null> 163
-PartsSupplier pg_catalog matpg_relatt nspname 5 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:ffbf69c1-2e34-4764-a9b3-9a1b61bfd4af !
<null> 241
+PartsSupplier pg_catalog matpg_relatt nspname 5 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:f1998229-2c1a-47b7-8f46-9dda81446db6 !
<null> 242
PartsSupplier pg_catalog pg_namespace oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:688e5112-4083-4b67-b42c-62d9a614c59a !
<null> 162
PartsSupplier pg_catalog pg_class oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:c1e736ac-c9d4-4026-8904-23c90e6eb1c0 !
<null> 164
PartsSupplier pg_catalog pg_attribute oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:f735e545-a81c-4ee2-84d0-3ea35d4083a2 !
<null> 173
PartsSupplier pg_catalog pg_type oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:b6f64d16-b147-459d-8e84-1bd3048fb900 !
<null> 183
-PartsSupplier pg_catalog pg_index oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:09daed8d-b0b8-4552-a261-2b6c775b46b0 !
<null> 191
-PartsSupplier pg_catalog pg_am oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:f6517a63-8c14-4b73-a18d-afaa5dfb35d9 !
<null> 199
-PartsSupplier pg_catalog pg_proc oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:f20c9489-10ca-4596-8a37-24218b67f764 !
<null> 201
-PartsSupplier pg_catalog pg_trigger oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:2b75f0b1-7475-4ed5-9da3-d37a8a25f26a !
<null> 211
-PartsSupplier pg_catalog pg_database oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:382f9fc9-8c96-4df7-ab5d-04dfb47ee142 !
<null> 224
-PartsSupplier pg_catalog pg_user oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:e63613cb-01ee-4b37-8b91-99d1aac4dfcb !
<null> 233
-PartsSupplier pg_catalog pg_proc proallargtypes 9 <null> object 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Object 0 0 0 mmuid:bcbed548-176c-4116-a5d6-7638cb0206e1 !
<null> 209
-PartsSupplier pg_catalog pg_proc proargmodes 8 <null> object 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Object 0 0 0 mmuid:d9f36bdc-7b25-4af0-b9f5-a96aac6d3094 !
<null> 208
-PartsSupplier pg_catalog pg_proc proargnames 7 <null> object 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Object 0 0 0 mmuid:ffa4ac73-b549-470e-931f-dc36330cb8c4 !
<null> 207
-PartsSupplier pg_catalog pg_proc proargtypes 6 <null> object 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Object 0 0 0 mmuid:6796c2e7-48a4-4f9f-bc98-d47913e2491c !
<null> 206
-PartsSupplier pg_catalog pg_proc proname 2 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:bdf3ee1e-b5b7-48ab-b43c-4bbb2c8ae1e2 !
<null> 202
-PartsSupplier pg_catalog pg_proc pronamespace 10 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:a385751f-a31a-4d5d-9197-3fbd390b0251 !
<null> 210
-PartsSupplier pg_catalog pg_proc pronargs 5 <null> short 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Short 0 0 0 mmuid:9fb5a34a-3a7e-4d38-b7cd-239f28a3504e !
<null> 205
-PartsSupplier pg_catalog pg_proc proretset 3 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:b288b3aa-37f2-4a8e-8b1b-e932a2ce3e25 !
<null> 203
-PartsSupplier pg_catalog pg_proc prorettype 4 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:e0244e1d-431c-41fa-8194-1e357e2b688b !
<null> 204
+PartsSupplier pg_catalog pg_index oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:83ae2247-7eec-459f-b037-ffd3cdca0627 !
<null> 192
+PartsSupplier pg_catalog pg_am oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:3c67619c-7d8f-4378-b7e9-84a0451ea5e5 !
<null> 200
+PartsSupplier pg_catalog pg_proc oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:bdf3ee1e-b5b7-48ab-b43c-4bbb2c8ae1e2 !
<null> 202
+PartsSupplier pg_catalog pg_trigger oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:635b6634-632c-43c9-8cc7-bcaa016133e8 !
<null> 212
+PartsSupplier pg_catalog pg_database oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:689cde3b-a631-4f25-94b4-ff2ffe022b0f !
<null> 225
+PartsSupplier pg_catalog pg_user oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:bb78401d-d10c-43b1-af84-e4fa6b95db42 !
<null> 234
+PartsSupplier pg_catalog matpg_datatype oid 1 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:053375a4-3971-4705-9146-9ecc640022c2 !
<null> 245
+PartsSupplier pg_catalog pg_proc proallargtypes 9 <null> object 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Object 0 0 0 mmuid:a385751f-a31a-4d5d-9197-3fbd390b0251 !
<null> 210
+PartsSupplier pg_catalog pg_proc proargmodes 8 <null> object 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Object 0 0 0 mmuid:bcbed548-176c-4116-a5d6-7638cb0206e1 !
<null> 209
+PartsSupplier pg_catalog pg_proc proargnames 7 <null> object 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Object 0 0 0 mmuid:d9f36bdc-7b25-4af0-b9f5-a96aac6d3094 !
<null> 208
+PartsSupplier pg_catalog pg_proc proargtypes 6 <null> object 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Object 0 0 0 mmuid:ffa4ac73-b549-470e-931f-dc36330cb8c4 !
<null> 207
+PartsSupplier pg_catalog pg_proc proname 2 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:b288b3aa-37f2-4a8e-8b1b-e932a2ce3e25 !
<null> 203
+PartsSupplier pg_catalog pg_proc pronamespace 10 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:e5715456-245f-4846-b90b-01d06d1c3672 !
<null> 211
+PartsSupplier pg_catalog pg_proc pronargs 5 <null> short 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Short 0 0 0 mmuid:6796c2e7-48a4-4f9f-bc98-d47913e2491c !
<null> 206
+PartsSupplier pg_catalog pg_proc proretset 3 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:e0244e1d-431c-41fa-8194-1e357e2b688b !
<null> 204
+PartsSupplier pg_catalog pg_proc prorettype 4 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:9fb5a34a-3a7e-4d38-b7cd-239f28a3504e !
<null> 205
PartsSupplier pg_catalog pg_class relam 5 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:c2f92b1a-6ba0-4486-8936-f5185d926178 !
<null> 168
PartsSupplier pg_catalog pg_class relhasoids 9 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:3ac5a14a-1f9e-455b-8ea1-cf0878774fd7 !
<null> 172
PartsSupplier pg_catalog pg_class relhasrules 8 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:6c26fd66-2a4a-4ccf-949a-a06a858db7f6 !
<null> 171
PartsSupplier pg_catalog pg_class relkind 4 <null> char 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Character 0 0 0 mmuid:ef4359eb-6d51-4249-bfea-40bc0f407d10 !
<null> 167
PartsSupplier pg_catalog pg_class relname 2 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:5f9b50fa-8188-4048-93c2-3ad1587915df !
<null> 165
-PartsSupplier pg_catalog matpg_relatt relname 4 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:5cfb2b62-a912-4bfb-bf4f-51e107fe210c !
<null> 240
+PartsSupplier pg_catalog matpg_relatt relname 4 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:ffbf69c1-2e34-4764-a9b3-9a1b61bfd4af !
<null> 241
PartsSupplier pg_catalog pg_class relnamespace 3 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:4591ef08-bff8-4f3b-9de7-420f9c7f9d2b !
<null> 166
PartsSupplier pg_catalog pg_class relpages 7 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:44dee7d6-b6ae-44c7-85f2-e87364d8d059 !
<null> 170
PartsSupplier pg_catalog pg_class reltuples 6 <null> float 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Float 0 0 0 mmuid:b9ed4b49-5a7b-4ba4-863a-37fd95b2a34c !
<null> 169
PartsSupplier SYSADMIN VDBResources resourcePath 1 <null> string 0 255 false true false true true false false Nullable <null> <null> Searchable <null> <null> java.lang.String 0 255 10 mmuuid:b1bc5150-3dcc-452e-9e75-4a506997f612 !
<null> 27
-PartsSupplier pg_catalog pg_trigger tgargs 4 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:250d7c06-728a-4b2a-b557-91f2a69bb184 !
<null> 214
-PartsSupplier pg_catalog pg_trigger tgconstrname 8 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:da4b59ca-ebff-45a8-ad68-9777bc587813 !
<null> 218
-PartsSupplier pg_catalog pg_trigger tgconstrrelid 2 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:635b6634-632c-43c9-8cc7-bcaa016133e8 !
<null> 212
-PartsSupplier pg_catalog pg_trigger tgdeferrable 6 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:d70f020b-658c-4f58-86dc-0fbb12e2d8af !
<null> 216
-PartsSupplier pg_catalog pg_trigger tgfoid 3 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:64977f3e-f2a0-466e-a5d1-80bb058cbe08 !
<null> 213
-PartsSupplier pg_catalog pg_trigger tginitdeferred 7 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:bfbff036-caf2-4652-80cf-398af17ed7d1 !
<null> 217
-PartsSupplier pg_catalog pg_trigger tgnargs 5 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:0c20dbe7-5d89-411f-a8ab-3d77b999595b !
<null> 215
-PartsSupplier pg_catalog pg_trigger tgrelid 9 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:c010d12f-2074-45db-8e18-979cee2c45da !
<null> 219
+PartsSupplier pg_catalog pg_trigger tgargs 4 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:0c20dbe7-5d89-411f-a8ab-3d77b999595b !
<null> 215
+PartsSupplier pg_catalog pg_trigger tgconstrname 8 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:c010d12f-2074-45db-8e18-979cee2c45da !
<null> 219
+PartsSupplier pg_catalog pg_trigger tgconstrrelid 2 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:64977f3e-f2a0-466e-a5d1-80bb058cbe08 !
<null> 213
+PartsSupplier pg_catalog pg_trigger tgdeferrable 6 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:bfbff036-caf2-4652-80cf-398af17ed7d1 !
<null> 217
+PartsSupplier pg_catalog pg_trigger tgfoid 3 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:250d7c06-728a-4b2a-b557-91f2a69bb184 !
<null> 214
+PartsSupplier pg_catalog pg_trigger tginitdeferred 7 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:da4b59ca-ebff-45a8-ad68-9777bc587813 !
<null> 218
+PartsSupplier pg_catalog pg_trigger tgnargs 5 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:d70f020b-658c-4f58-86dc-0fbb12e2d8af !
<null> 216
+PartsSupplier pg_catalog pg_trigger tgrelid 9 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:71091853-c65e-46a9-9947-aa024f806e2d !
<null> 220
PartsSupplier pg_catalog pg_type typbasetype 6 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:a17d2f61-cd68-4c0d-8d25-132f68eb3b67 !
<null> 188
+PartsSupplier pg_catalog pg_type typelem 9 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:22ac431d-e6e6-4eef-9d74-b31795424e97 !
<null> 191
PartsSupplier pg_catalog pg_type typlen 4 <null> short 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Short 0 0 0 mmuid:931c09e1-937a-437e-aab2-2360f8d90e2b !
<null> 186
+PartsSupplier pg_catalog matpg_datatype typlen 5 <null> short 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Short 0 0 0 mmuid:0e9c4439-48d0-4115-a343-5baab7a236b6 !
<null> 249
PartsSupplier pg_catalog pg_type typname 2 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:d600d818-2aad-4c92-9343-267d044dd97d !
<null> 184
+PartsSupplier pg_catalog matpg_datatype typname 2 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:0f312b3c-98ca-4a09-81fa-f1ff83f0a6c1 !
<null> 246
PartsSupplier pg_catalog pg_type typnamespace 3 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:e47217d2-2b07-4353-bfbd-d7c883a5e7e0 !
<null> 185
+PartsSupplier pg_catalog matpg_relatt typoid 7 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:595a823f-cec1-42dc-b8b2-c95c8b4e4e66 !
<null> 244
PartsSupplier pg_catalog pg_type typrelid 8 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:bec25882-b292-4ed1-a610-cad5d504837d !
<null> 190
PartsSupplier pg_catalog pg_type typtype 5 <null> char 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Character 0 0 0 mmuid:83199eba-7af4-44a9-822f-006677b1b895 !
<null> 187
PartsSupplier pg_catalog pg_type typtypmod 7 <null> integer 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Integer 0 0 0 mmuid:cee3559d-1ce6-4b17-ad57-2ecb79a9e1d2 !
<null> 189
-PartsSupplier pg_catalog pg_user usecreatedb 3 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:236445e1-408c-40a1-a61c-40e96fb5dc9f !
<null> 235
-PartsSupplier pg_catalog pg_user usename 2 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:bb78401d-d10c-43b1-af84-e4fa6b95db42 !
<null> 234
-PartsSupplier pg_catalog pg_user usesuper 4 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:6da98878-b46e-4ed1-b032-1bc72da595f4 !
<null> 236
-Row Count : 242
+PartsSupplier pg_catalog matpg_datatype uid 4 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:87826ebc-98a5-4f19-a6d8-6b7b96cbed48 !
<null> 248
+PartsSupplier pg_catalog pg_user usecreatedb 3 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:6da98878-b46e-4ed1-b032-1bc72da595f4 !
<null> 236
+PartsSupplier pg_catalog pg_user usename 2 <null> string 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.String 0 0 0 mmuid:236445e1-408c-40a1-a61c-40e96fb5dc9f !
<null> 235
+PartsSupplier pg_catalog pg_user usesuper 4 <null> boolean 0 0 false true false false false false false Unknown <null> <null> Searchable <null> <null> java.lang.Boolean 0 0 0 mmuid:9bfddc66-af75-4366-8eac-b9fef3421219 !
<null> 237
+Row Count : 249
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
VDBName 12 PartsSupplier java.lang.String VDBName string SYS Columns 255 255 0 false false false false 0 true true false false
SchemaName 12 PartsSupplier java.lang.String SchemaName string SYS Columns 255 255 0 false true false true 1 false true true true
Modified: trunk/test-integration/common/src/test/resources/TestSystemVirtualModel/testKeyColumns.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestSystemVirtualModel/testKeyColumns.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestSystemVirtualModel/testKeyColumns.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -9,16 +9,20 @@
PartsSupplier PartsSupplier PARTSSUPPLIER.SUPPLIER SUPPLIER_ID PK_SUPPLIER Primary <null> mmuuid:375c8380-73ff-1edc-a81c-ecf397b10590 1 8
PartsSupplier PartsSupplier PARTSSUPPLIER.SUPPLIER_PARTS SUPPLIER_ID PK_SUPPLIER_PARTS Primary <null> mmuuid:455e5440-73ff-1edc-a81c-ecf397b10590 1 4
PartsSupplier PartsSupplier PARTSSUPPLIER.SUPPLIER SUPPLIER_STATUS FK_SPLIER_STATS Foreign mmuuid:25a8a740-73ff-1edc-a81c-ecf397b10590 mmuuid:5ac43c00-73ff-1edc-a81c-ecf397b10590 1 9
-PartsSupplier pg_catalog matpg_relatt attname pk_matpg_relatt_names Primary <null> mmuid:23454408-0347-40d2-a3f9-3faa664fb5e9 1 14
-PartsSupplier pg_catalog matpg_relatt attnum idx_matpg_relatt_ids Index <null> mmuid:595a823f-cec1-42dc-b8b2-c95c8b4e4e66 2 18
-PartsSupplier pg_catalog matpg_relatt attrelid idx_matpg_relatt_ids Index <null> mmuid:595a823f-cec1-42dc-b8b2-c95c8b4e4e66 1 17
-PartsSupplier pg_catalog matpg_relatt nspname pk_matpg_relatt_names Primary <null> mmuid:23454408-0347-40d2-a3f9-3faa664fb5e9 3 16
+PartsSupplier pg_catalog matpg_relatt attname pk_matpg_relatt_names Primary <null> mmuid:559efade-b320-49bd-8524-1d325ae11c82 1 14
+PartsSupplier pg_catalog matpg_relatt attnum idx_matpg_relatt_ids Index <null> mmuid:349f0c8c-7c64-4e0a-a84a-aee3deaf83af 2 18
+PartsSupplier pg_catalog matpg_relatt attrelid idx_matpg_relatt_ids Index <null> mmuid:349f0c8c-7c64-4e0a-a84a-aee3deaf83af 1 17
+PartsSupplier pg_catalog matpg_datatype name matpg_datatype_names Primary <null> mmuid:eda814fb-0a5a-4fbf-87bc-b57952292038 2 20
+PartsSupplier pg_catalog matpg_relatt nspname pk_matpg_relatt_names Primary <null> mmuid:559efade-b320-49bd-8524-1d325ae11c82 3 16
+PartsSupplier pg_catalog matpg_datatype oid matpg_datatype_ids Index <null> mmuid:443a2ab3-8257-4c4c-838e-9a47deaf4cf9 2 22
+PartsSupplier pg_catalog matpg_datatype oid matpg_datatype_names Primary <null> mmuid:eda814fb-0a5a-4fbf-87bc-b57952292038 1 19
PartsSupplier pg_catalog pg_attribute oid pk_pg_attr Primary <null> mmuid:649c1635-60ad-4c28-9b20-035c562bb1be 1 11
PartsSupplier pg_catalog pg_class oid pk_pg_class Primary <null> mmuid:59f7dc95-95fe-4d90-9813-1a097188e768 1 10
-PartsSupplier pg_catalog pg_index oid pk_pg_index Primary <null> mmuid:347ec08c-6b41-41d0-8475-031ce7d99ac0 1 12
-PartsSupplier pg_catalog pg_proc oid pk_pg_proc Primary <null> mmuid:e5715456-245f-4846-b90b-01d06d1c3672 1 13
-PartsSupplier pg_catalog matpg_relatt relname pk_matpg_relatt_names Primary <null> mmuid:23454408-0347-40d2-a3f9-3faa664fb5e9 2 15
-Row Count : 18
+PartsSupplier pg_catalog pg_index oid pk_pg_index Primary <null> mmuid:1462b28e-0bab-436f-9654-013821506337 1 12
+PartsSupplier pg_catalog pg_proc oid pk_pg_proc Primary <null> mmuid:9569efdb-21b2-4b4f-a2db-e7406267b8ed 1 13
+PartsSupplier pg_catalog matpg_relatt relname pk_matpg_relatt_names Primary <null> mmuid:559efade-b320-49bd-8524-1d325ae11c82 2 15
+PartsSupplier pg_catalog matpg_datatype typname matpg_datatype_ids Index <null> mmuid:443a2ab3-8257-4c4c-838e-9a47deaf4cf9 1 21
+Row Count : 22
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
VDBName 12 PartsSupplier java.lang.String VDBName string SYS KeyColumns 255 255 0 false false false false 0 true true false false
SchemaName 12 PartsSupplier java.lang.String SchemaName string SYS KeyColumns 255 255 0 false true false true 1 false true true true
Modified: trunk/test-integration/common/src/test/resources/TestSystemVirtualModel/testKeys.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestSystemVirtualModel/testKeys.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestSystemVirtualModel/testKeys.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -8,13 +8,15 @@
PartsSupplier PartsSupplier PARTSSUPPLIER.STATUS PK_STATUS <null> <null> Primary false <null> mmuuid:25a8a740-73ff-1edc-a81c-ecf397b10590 3
PartsSupplier PartsSupplier PARTSSUPPLIER.SUPPLIER PK_SUPPLIER <null> <null> Primary false <null> mmuuid:375c8380-73ff-1edc-a81c-ecf397b10590 7
PartsSupplier PartsSupplier PARTSSUPPLIER.SUPPLIER_PARTS PK_SUPPLIER_PARTS <null> <null> Primary false <null> mmuuid:455e5440-73ff-1edc-a81c-ecf397b10590 4
-PartsSupplier pg_catalog matpg_relatt idx_matpg_relatt_ids <null> <null> Index false <null> mmuid:595a823f-cec1-42dc-b8b2-c95c8b4e4e66 14
-PartsSupplier pg_catalog matpg_relatt pk_matpg_relatt_names <null> <null> Primary false <null> mmuid:23454408-0347-40d2-a3f9-3faa664fb5e9 13
+PartsSupplier pg_catalog matpg_relatt idx_matpg_relatt_ids <null> <null> Index false <null> mmuid:349f0c8c-7c64-4e0a-a84a-aee3deaf83af 14
+PartsSupplier pg_catalog matpg_datatype matpg_datatype_ids <null> <null> Index false <null> mmuid:443a2ab3-8257-4c4c-838e-9a47deaf4cf9 16
+PartsSupplier pg_catalog matpg_datatype matpg_datatype_names <null> <null> Primary false <null> mmuid:eda814fb-0a5a-4fbf-87bc-b57952292038 15
+PartsSupplier pg_catalog matpg_relatt pk_matpg_relatt_names <null> <null> Primary false <null> mmuid:559efade-b320-49bd-8524-1d325ae11c82 13
PartsSupplier pg_catalog pg_attribute pk_pg_attr <null> <null> Primary false <null> mmuid:649c1635-60ad-4c28-9b20-035c562bb1be 10
PartsSupplier pg_catalog pg_class pk_pg_class <null> <null> Primary false <null> mmuid:59f7dc95-95fe-4d90-9813-1a097188e768 9
-PartsSupplier pg_catalog pg_index pk_pg_index <null> <null> Primary false <null> mmuid:347ec08c-6b41-41d0-8475-031ce7d99ac0 11
-PartsSupplier pg_catalog pg_proc pk_pg_proc <null> <null> Primary false <null> mmuid:e5715456-245f-4846-b90b-01d06d1c3672 12
-Row Count : 14
+PartsSupplier pg_catalog pg_index pk_pg_index <null> <null> Primary false <null> mmuid:1462b28e-0bab-436f-9654-013821506337 11
+PartsSupplier pg_catalog pg_proc pk_pg_proc <null> <null> Primary false <null> mmuid:9569efdb-21b2-4b4f-a2db-e7406267b8ed 12
+Row Count : 16
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
VDBName 12 PartsSupplier java.lang.String VDBName string SYS Keys 255 255 0 false false false false 0 true true false false
SchemaName 12 PartsSupplier java.lang.String SchemaName string SYS Keys 255 255 0 false true false true 1 false true true true
Modified: trunk/test-integration/common/src/test/resources/TestSystemVirtualModel/testTables.expected
===================================================================
--- trunk/test-integration/common/src/test/resources/TestSystemVirtualModel/testTables.expected 2011-04-12 19:35:57 UTC (rev 3083)
+++ trunk/test-integration/common/src/test/resources/TestSystemVirtualModel/testTables.expected 2011-04-12 23:20:51 UTC (rev 3084)
@@ -18,19 +18,20 @@
PartsSupplier SYS Tables Table <null> true false mmuuid:8551b3bd-11cc-4049-9bcf-fe91a0eb7ba7 0 <null> true false 17
PartsSupplier SYSADMIN VDBResources Table <null> true false mmuuid:1785804d-beaf-4831-9531-e59164fedd49 0 <null> true false 7
PartsSupplier SYS VirtualDatabases Table <null> true false mmuuid:47297c72-d621-4f4e-af4e-74060ac5f489 0 <null> true false 18
-PartsSupplier pg_catalog matpg_relatt Table <null> false false mmuid:9bfddc66-af75-4366-8eac-b9fef3421219 0 <null> true true 30
-PartsSupplier pg_catalog pg_am Table <null> false false mmuid:1462b28e-0bab-436f-9654-013821506337 0 <null> true false 24
-PartsSupplier pg_catalog pg_attrdef Table <null> false false mmuid:71091853-c65e-46a9-9947-aa024f806e2d 0 <null> true false 27
+PartsSupplier pg_catalog matpg_datatype Table <null> false false mmuid:17448311-6679-4dfd-aeb6-4aabbd894729 0 <null> true true 31
+PartsSupplier pg_catalog matpg_relatt Table <null> false false mmuid:8c0714d6-1c72-40b4-8528-3b2c63059107 0 <null> true true 30
+PartsSupplier pg_catalog pg_am Table <null> false false mmuid:f6517a63-8c14-4b73-a18d-afaa5dfb35d9 0 <null> true false 24
+PartsSupplier pg_catalog pg_attrdef Table <null> false false mmuid:76a7dd05-9a7d-4243-b561-f3056500dcaf 0 <null> true false 27
PartsSupplier pg_catalog pg_attribute Table <null> false false mmuid:fa463d98-365f-489a-a707-025193cb51eb 0 <null> true true 21
PartsSupplier pg_catalog pg_class Table <null> false false mmuid:7e21f2e6-06e3-4bca-9b01-72ea47821560 0 <null> true true 20
-PartsSupplier pg_catalog pg_database Table <null> false false mmuid:492dd834-907f-429b-aa6e-958ad65204c6 0 <null> true false 28
-PartsSupplier pg_catalog pg_index Table <null> false false mmuid:22ac431d-e6e6-4eef-9d74-b31795424e97 0 <null> true true 23
+PartsSupplier pg_catalog pg_database Table <null> false false mmuid:382f9fc9-8c96-4df7-ab5d-04dfb47ee142 0 <null> true false 28
+PartsSupplier pg_catalog pg_index Table <null> false false mmuid:09daed8d-b0b8-4552-a261-2b6c775b46b0 0 <null> true true 23
PartsSupplier pg_catalog pg_namespace Table <null> false false mmuid:6609866a-3d7b-4f4b-95fe-ebfac769d699 0 <null> true false 19
-PartsSupplier pg_catalog pg_proc Table <null> false false mmuid:da4b747e-7d87-403a-8309-2cdf1399031b 0 <null> true true 25
-PartsSupplier pg_catalog pg_trigger Table <null> false false mmuid:9569efdb-21b2-4b4f-a2db-e7406267b8ed 0 <null> true false 26
+PartsSupplier pg_catalog pg_proc Table <null> false false mmuid:f20c9489-10ca-4596-8a37-24218b67f764 0 <null> true true 25
+PartsSupplier pg_catalog pg_trigger Table <null> false false mmuid:2b75f0b1-7475-4ed5-9da3-d37a8a25f26a 0 <null> true false 26
PartsSupplier pg_catalog pg_type Table <null> false false mmuid:9462e3f8-cd3c-414f-a570-f6f33c40e36a 0 <null> true false 22
-PartsSupplier pg_catalog pg_user Table <null> false false mmuid:28d034eb-6f39-402f-b642-9c9560e57247 0 <null> true false 29
-Row Count : 30
+PartsSupplier pg_catalog pg_user Table <null> false false mmuid:e63613cb-01ee-4b37-8b91-99d1aac4dfcb 0 <null> true false 29
+Row Count : 31
getColumnName getColumnType getCatalogName getColumnClassName getColumnLabel getColumnTypeName getSchemaName getTableName getColumnDisplaySize getPrecision getScale isAutoIncrement isCaseSensitive isCurrency isDefinitelyWritable isNullable isReadOnly isSearchable isSigned isWritable
VDBName 12 PartsSupplier java.lang.String VDBName string SYS Tables 255 255 0 false true false true 1 false true true true
SchemaName 12 PartsSupplier java.lang.String SchemaName string SYS Tables 255 255 0 false true false true 1 false true true true
Added: trunk/test-integration/common/src/test/resources/bqt.vdb
===================================================================
(Binary files differ)
Property changes on: trunk/test-integration/common/src/test/resources/bqt.vdb
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
13 years, 8 months