You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by "Amita Vadhavkar (JIRA)" <tu...@ws.apache.org> on 2007/07/04 15:28:10 UTC

[jira] Commented: (TUSCANY-1355) DAS-RDB does not support Oracle or SqlServer well

    [ https://issues.apache.org/jira/browse/TUSCANY-1355?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12510173 ] 

Amita Vadhavkar commented on TUSCANY-1355:
------------------------------------------

This might be imcompatibility in SDO, not sure, will you please list here all the sdo and das jars
(exact with versions) you are using? 
Also, will you please check using RDB DAS beta1 binary distribution at http://people.apache.org/~lresende/tuscany/das-beta1-distribution/  instead of building it from scratch, please use all the same jars provided in there.

Regards

> DAS-RDB does not support Oracle or SqlServer well
> -------------------------------------------------
>
>                 Key: TUSCANY-1355
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-1355
>             Project: Tuscany
>          Issue Type: Bug
>          Components: Java DAS RDB
>    Affects Versions: Java-DAS-M2
>         Environment: DAS-RDB to access the database of Oracle
>            Reporter: wangful
>
> I have used the following simple codes to use DAS to access an Oracle database.
> 		//String url = "jdbc:db2j:D:/RAD6/runtimes/base_v6/cloudscape/DAS";
> 		String url = "jdbc:oracle:thin:wcs/wcs1@//raptor08:1521/g10";
> 		String query = "select * from MYCUSTOMER";
> 		String query_result="";
> 		Connection conn = null;
> 	//	Class.forName("com.ibm.db2j.jdbc.DB2jDriver").newInstance();
> 		DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
> 		conn = DriverManager.getConnection(url);
> 		conn.setAutoCommit(false);
>                                            DAS das = DAS.FACTORY.createDAS(conn);
> 		Command readStores = das.createCommand(query);
> 		DataObject root = (DataObject)readStores.executeQuery();
> 		DataObject cus1 = root.getDataObject("MYCUSTOMER[1]");
> 		
> 		System.out.println(root.getInt("MYCUSTOMER[1]/ID"));
> 		System.out.println(root.getString("MYCUSTOMER[1]/NAME"));
> It will caused the following error: 
> Exception in thread "main" java.lang.IllegalArgumentException: Class 'DataGraphRoot' does not have a feature named 'MYCUSTOMER'
> 	at org.apache.tuscany.sdo.util.DataObjectUtil.getOpenFeature(DataObjectUtil.java:1804)
> 	at org.apache.tuscany.sdo.util.DataObjectUtil.getProperty(DataObjectUtil.java:2367)
> 	at org.apache.tuscany.sdo.impl.DataObjectImpl.getProperty(DataObjectImpl.java:1287)
> 	at org.apache.tuscany.sdo.util.DataObjectUtil$Accessor.setFeatureName(DataObjectUtil.java:2054)
> 	at org.apache.tuscany.sdo.util.DataObjectUtil$Accessor.process(DataObjectUtil.java:2161)
> 	at org.apache.tuscany.sdo.util.DataObjectUtil$Accessor.init(DataObjectUtil.java:1940)
> 	at org.apache.tuscany.sdo.util.DataObjectUtil$Accessor.create(DataObjectUtil.java:1860)
> 	at org.apache.tuscany.sdo.util.DataObjectUtil.get(DataObjectUtil.java:744)
> 	at org.apache.tuscany.sdo.impl.DataObjectImpl.get(DataObjectImpl.java:216)
> 	at org.apache.tuscany.sdo.impl.DataObjectImpl.getDataObject(DataObjectImpl.java:326)
> 	at TestDAS.main(TestDAS.java:47)
> But the same code and same config will work well for  cloudscape database.
> There are also some other problems for Oracle, seems DAS can't work for oracle.
> Will someone look into this problem?
> Thanks.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org