You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Rick Hillegas (JIRA)" <ji...@apache.org> on 2010/01/29 23:33:34 UTC
[jira] Updated: (DERBY-4484) Add import/export support for UDTs.
[ https://issues.apache.org/jira/browse/DERBY-4484?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Rick Hillegas updated DERBY-4484:
---------------------------------
Attachment: derby-4484-01-ac-basicExportImport.diff
Attaching derby-4484-01-ac-basicExportImport.diff. This adds basic support for exporting and importing UDT columns. UDTs can be exported and imported alongside other columns to/from a file. Regression tests are running.
This patch does NOT support dumping and retrieving UDT columns to/from a side file devoted to large objects--as can be done for LOBs and large binary columns. But that would be a useful next improvement.
In exporting a UDT column, it is serialized first to a byte array. Then that array is turned into a hex string just like a VARBINARY column. Importing the UDT reverses this process.
Touches the following files:
---------
M java/engine/org/apache/derby/iapi/types/DataTypeDescriptor.java
M java/engine/org/apache/derby/catalog/types/BaseTypeIdImpl.java
M java/engine/org/apache/derby/catalog/types/UserDefinedTypeIdImpl.java
M java/engine/org/apache/derby/impl/sql/compile/ValueNode.java
Type system support for UDTs was improved to make it possible to create a UDT descriptor from the schema qualified name of the type. The Import VTI needs this. Along the way, the ValueNode was improved to bind a classname to these UDT descriptors.
---------
M java/engine/org/apache/derby/impl/load/ExportAbstract.java
M java/engine/org/apache/derby/impl/load/ColumnInfo.java
M java/engine/org/apache/derby/impl/load/Import.java
M java/engine/org/apache/derby/impl/load/ImportResultSetMetaData.java
M java/engine/org/apache/derby/impl/load/ImportAbstract.java
Changes to export and import to allow UDT columns in exported files. The import machinery is a little tricky because it relies on a VTI, whose metadata descriptions had to be improved.
---------
M java/engine/org/apache/derby/impl/sql/compile/CreateTableNode.java
The ImportExportTest uncovered some flaws in CREATE TABLE AS which prevented us from creating a table's shape from a query if one of the result columns was of UDT type. Fixed in this patch.
---------
M java/testing/org/apache/derbyTesting/functionTests/tests/lang/UDTTest.java
M java/testing/org/apache/derbyTesting/functionTests/tests/tools/ImportExportTest.java
Regression tests for basic export/import of UDT columns.
---------
> Add import/export support for UDTs.
> -----------------------------------
>
> Key: DERBY-4484
> URL: https://issues.apache.org/jira/browse/DERBY-4484
> Project: Derby
> Issue Type: Improvement
> Components: SQL
> Affects Versions: 10.6.0.0
> Reporter: Rick Hillegas
> Attachments: derby-4484-01-ac-basicExportImport.diff
>
>
> Import/export should work on UDTs.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.