jdbc-oracle: metadata query not compatible with oracle 9
--------------------------------------------------------
Key: GEOT-2149
URL: http://jira.codehaus.org/browse/GEOT-2149
Project: GeoTools
Issue Type: Improvement
Components: data jdbc-ng
Affects Versions: 2.5.1
Reporter: Mauro Bartolomeoli
Fix For: 2.5.2
The query used in OracleDialect (method public Class<?> getMapping(ResultSet
columnMetaData, Connection cx) ) to retrieve geometry type is not compatible
with oracle 9 (where the all_sdo_index_info view doesn't contain the column
table_owner). The query could be easily rewritten to be backwardly compatible.
Current query:
SELECT META.SDO_LAYER_GTYPE
FROM MDSYS.ALL_SDO_INDEX_INFO INFO
INNER JOIN MDSYS.USER_SDO_INDEX_METADATA META
ON INFO.INDEX_NAME = META.SDO_INDEX_NAME
WHERE INFO.TABLE_NAME = '<tableName>'
AND INFO.COLUMN_NAME = '<columnName>'
AND INFO.TABLE_OWNER = '<schema>'
Oracle 9 compatible query:
SELECT META.SDO_LAYER_GTYPE
FROM all_indexes INFO
INNER JOIN MDSYS.USER_SDO_INDEX_METADATA META
ON INFO.INDEX_NAME = META.SDO_INDEX_NAME
WHERE INFO.TABLE_NAME = '<tableName>'
AND REPLACE(meta.sdo_column_name, '"') = '<columnName>'
and info.table_owner='<schema>'
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Geotools-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-devel