[
https://jira.jboss.org/browse/TEIIDDES-581?page=com.atlassian.jira.plugin...
]
Barry LaFond commented on TEIIDDES-581:
---------------------------------------
Running in Debug I discovered that during the "Setting of an EObject's
description" (i.e. BaseTableImpl), there is an ultimate check in
ModelResourceContainerFactory to see if the ModelType supports annotations. In this case,
the MtkXmiResourceImpl's ModelType is Default or "UNKNOWN" and fails the
test. Hence descriptions aren't allowed.
Because of the "dual resource" nature of the import process, somehow the
TransientModelSelector's MtkXmiResource needs to have the ModelType changed.
The attached patch exposes that resource via a getter in TransientModelSelector and prior
to creating the model objects, make a call to
getModelAnnotation().setModelType(ModelType.PHYSICAL_LITERAL)
Not sure if this is the best way to handle it, but ModelAnnotations (i.e. Descriptions)
can't be created/set without the proper ModelType.
NPE importing DDL into Relational Model with "Set description of
model entities to corresponding DDL statement" option checked
------------------------------------------------------------------------------------------------------------------------------
Key: TEIIDDES-581
URL:
https://jira.jboss.org/browse/TEIIDDES-581
Project: Teiid Designer
Issue Type: Bug
Components: Import/Export
Environment: Error was reproduced on Linux in my Eclipse IDE, using a 3.6 Helios
w/Teiid Designer CR1 installed and 3.6 Helios with JBoss aggregate build:
jbosstools-3.2.0.M2.aggregate-Update-2010-08-26_02-57-10-H188.zip
Reporter: Barry LaFond
Assignee: John Verhaeg
Priority: Critical
Fix For: 7.1
Attachments: org.teiid.designer.compare.patch,
org.teiid.designer.ddl.importer.patch, ProductsDB2.ddl, ProductsSQLServer.ddl,
TEIIDDES_581.txt
I exported Products relational model into both DB2 and SQL Server DDL files.
Tried importing them into relational models and checking the "Set description of
model entities to corresponding DDL statement" option.
In both cases I got NPE's hitting "Next>" or "Finish".
See attacheck DDL and Stacktrace log.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira