On Wed, 26 May 2004 17:43:07 +0200, [EMAIL PROTECTED] wrote:
>
>Dear Sir or Madam,
>
>I will make a persitence layer which is independant from my data
>storemedium.
>Now my question : Is it possible to make a OQL-Statement for a XML-File
>similiar
>you can do it with JDO ?
Chris, afaik, without any changes to the Castor code base, this will not be
achievable. In addition, I do not think that OQL is a language well-suited for
your task, either. If you really, really wanted to use OQL in the way descibed, you
would have to amend Castor (source code) yourself, a task not really
trivial.
Thanks
Werner
>
>I want to show my question clearly in a short example :
>
>Ex1. Actor.xml
>-------------------
>
><?xml version="1.0" encoding="UTF-8"?>
><actors>
> <actor personal-iD="100">
> <address>
> <city>munich</city>
> <street>kornstr. 24</street>
> </address>
> <last-name>Schmidt</last-name>
> <first-name>Hans</first-name>
> <tel-number>040/123458</tel-number>
> </actor>
>
> <actor personal-iD="101">
> <last-name>Fleisch</last-name><
> first-name>Stefan</first-name>
> <tel-number>024/252525</tel-number>
> </actor>
></actors>
>
>In a Database the hole thing will looks like this :
>
>Ex2. Table Actor
>---------------------
>personal-ID lastName firstName ....
>100 � Schmidt Hans ...
>200 Fleisch Stefan ...
>
>Now I want to get the actor with the personal-ID 200. If my data were
>stored in a database (Ex2) I can say :
>
>oql = db.getOQLQuery( "SELECT ... WHERE personal-ID = 200 );
>
>and get only the actor with the ID 200. Can I get the record similar by
>unmarshalling the Actor.xml in Example 1 ?
>
>I think the Castor XML API is strictly seperated from the Castor JDO
>API,
>but I also think that I'm not the only one who want unmarshalling only a
>few
>objects from a XML-File and want to change them.
>
>Is there a solution for my problem in the castor api, or haven't I the
>possibility to make a OQL-Statement to a XML data storemedium ?
>
>Best regards
>
>Chris
>
>
>
>-----------------------------------------------------------
>If you wish to unsubscribe from this mailing, send mail to
>[EMAIL PROTECTED] with a subject of:
> unsubscribe castor-user
>
-----------------------------------------------------------
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
unsubscribe castor-user