[jira] Updated: (TUSCANY-1929) generate xml from dataobject

2007-12-05 Thread Kristina (JIRA)

 [ 
https://issues.apache.org/jira/browse/TUSCANY-1929?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Kristina  updated TUSCANY-1929:
---

Description: 
hi all,
not sure if this is a bug or is just me... bottom line i need help :)

when trying to generate the xml from dataobject , i get an empty one eventhough 
the dataobject is filled
I am using: String generatedXml = XMLHelper.INSTANCE.save(root, 
"http://helloworld2";, "MaterialListForTest"); where root is my dataobject

what am i doing wrong?

thanks,

kristina

  was:
hi all,
not sure if this is a bug or is just me... bottom line i need help :)

i am trying to use das to read data from an access mdb into an dataobject (sdo)
DAS das = DAS.FACTORY.createDAS(con);
String sql = "select * from [" + tablename+ "] ;
Command readTableData = das.createCommand(sql);
DataObject root = readTableData.executeQuery();

when trying to run the code above, i get 
Table WD Peripheral HD Controller in query does not include Primary Key column 
or has null value in it, can not proceed!

same error if i set the pk using ConfigHelper.addprimarykey(pk)
same error if the sql string contains all fields from the table, pk included

 error message **

java.lang.RuntimeException: Table WD Peripheral HD Controller in query does not 
include Primary Key column or has null value in it, can not proceed!
at 
org.apache.tuscany.das.rdb.graphbuilder.impl.ResultSetProcessor.addRowToGraph(ResultSetProcessor.java:117)
at 
org.apache.tuscany.das.rdb.graphbuilder.impl.ResultSetProcessor.processResultSet(ResultSetProcessor.java:91)
at 
org.apache.tuscany.das.rdb.graphbuilder.impl.ResultSetProcessor.processResults(ResultSetProcessor.java:77)
at 
org.apache.tuscany.das.rdb.impl.ReadCommandImpl.buildGraph(ReadCommandImpl.java:309)
at 
org.apache.tuscany.das.rdb.impl.ReadCommandImpl.executeQuery(ReadCommandImpl.java:277)

*** end error message ***

if the sql string looks like this: String sql = "select " + pk + " from [" + 
tablename+ "] "; i get no error message but when trying to generate the xml 
from dataobject root, i get an empty one.
String generatedXml = XMLHelper.INSTANCE.save(root, "http://helloworld2";, 
"MaterialListForTest");

what am i doing wrong?

thanks,

kristina

Summary: generate xml from dataobject  (was: when query does not 
include only pk , java.lang.RuntimeException is returned)

> generate xml from dataobject
> 
>
> Key: TUSCANY-1929
> URL: https://issues.apache.org/jira/browse/TUSCANY-1929
> Project: Tuscany
>  Issue Type: Bug
>  Components: Java DAS RDB
>Affects Versions: Java-DAS-M2
> Environment: java ee 1.5, eclipse 3.3.1.1. , windows xp, das 1.0 beta 
> 2, access mdb - no access installed, sca 1.0
>Reporter: Kristina 
>
> hi all,
> not sure if this is a bug or is just me... bottom line i need help :)
> when trying to generate the xml from dataobject , i get an empty one 
> eventhough the dataobject is filled
> I am using: String generatedXml = XMLHelper.INSTANCE.save(root, 
> "http://helloworld2";, "MaterialListForTest"); where root is my dataobject
> what am i doing wrong?
> thanks,
> kristina

-- 
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: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[jira] Created: (TUSCANY-1929) when query does not include only pk , java.lang.RuntimeException is returned

2007-12-05 Thread Kristina (JIRA)
when query does not include only pk , java.lang.RuntimeException is returned


 Key: TUSCANY-1929
 URL: https://issues.apache.org/jira/browse/TUSCANY-1929
 Project: Tuscany
  Issue Type: Bug
  Components: Java DAS RDB
Affects Versions: Java-DAS-M2
 Environment: java ee 1.5, eclipse 3.3.1.1. , windows xp, das 1.0 beta 
2, access mdb - no access installed, sca 1.0
Reporter: Kristina 


hi all,
not sure if this is a bug or is just me... bottom line i need help :)

i am trying to use das to read data from an access mdb into an dataobject (sdo)
DAS das = DAS.FACTORY.createDAS(con);
String sql = "select * from [" + tablename+ "] ;
Command readTableData = das.createCommand(sql);
DataObject root = readTableData.executeQuery();

when trying to run the code above, i get 
Table WD Peripheral HD Controller in query does not include Primary Key column 
or has null value in it, can not proceed!

same error if i set the pk using ConfigHelper.addprimarykey(pk)
same error if the sql string contains all fields from the table, pk included

 error message **

java.lang.RuntimeException: Table WD Peripheral HD Controller in query does not 
include Primary Key column or has null value in it, can not proceed!
at 
org.apache.tuscany.das.rdb.graphbuilder.impl.ResultSetProcessor.addRowToGraph(ResultSetProcessor.java:117)
at 
org.apache.tuscany.das.rdb.graphbuilder.impl.ResultSetProcessor.processResultSet(ResultSetProcessor.java:91)
at 
org.apache.tuscany.das.rdb.graphbuilder.impl.ResultSetProcessor.processResults(ResultSetProcessor.java:77)
at 
org.apache.tuscany.das.rdb.impl.ReadCommandImpl.buildGraph(ReadCommandImpl.java:309)
at 
org.apache.tuscany.das.rdb.impl.ReadCommandImpl.executeQuery(ReadCommandImpl.java:277)

*** end error message ***

if the sql string looks like this: String sql = "select " + pk + " from [" + 
tablename+ "] "; i get no error message but when trying to generate the xml 
from dataobject root, i get an empty one.
String generatedXml = XMLHelper.INSTANCE.save(root, "http://helloworld2";, 
"MaterialListForTest");

what am i doing wrong?

thanks,

kristina

-- 
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: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]