Sorry, that wasn't intended a criticism, just a pointer as some of the OQL
examples in the doc won't work. OJB looks to be a great util.

Neil :)

-----Original Message-----
From: Neil Blue 
Sent: 18 November 2002 16:00
To: 'OJB Users List'
Subject: RE: simple OQL where syntax


I used the logger too, but it looks like some fundimental gaps in OJB at the
moment. here is an OQL link:

http://www.computing.surrey.ac.uk/personal/st/D.Barton/CS363/4d-OQL.pdf

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: 18 November 2002 16:00
To: OJB Users List
Subject: Re: simple OQL where syntax



I am new to OBJ too.  Where did you find OQL reference?  I could not find
anything other than the tutorial2.  I even bought the ODMG book.  Instead
of using select *, I used "select del" as in tutorial2.  I could not even
found any reference of del in the ODMG book.  Another thing I did was turn
on the logger to info level so that I can see the SQL statement generated.

Hope this helps.  Please let me know where to find OQL reference.

Thank you,

Jane


 

                    Neil Blue

                    <Neil.Blue@denovop       To:
"'[EMAIL PROTECTED]'"            
                    harma.com>                <[EMAIL PROTECTED]>

                                             cc:

                    11/18/2002 08:48         Subject:     simple OQL where
syntax               
                    AM

                    Please respond to

                    "OJB Users List"

 

 





Hello,

I have now got OJB up and running with the ODMG interface, from within
JBoss.

Now I am starting to look into OQL, but I have a few questions after
reading
an OQL doc and trying it out on ODJ

1) when I try using a table name alias like:

select * from com.novobase.jaxbjdo.Minimol m where m.name='MyName#2'

I get the error:

unexpected token: m

2) when I try without:

select * from com.novobase.jaxbjdo.Minimol where name='MyName#2'

I get the error:

ClassCastException: java.lang.Character

3) when I try:

select * from com.novobase.jaxbjdo.Minimol where name="MyName#2"

I get the error:

Invalid column name (this is an oracle error)

4) If i try bind:

select * from com.novobase.jaxbjdo.Minimol where name=?

then use:
query.bind("MyName#2");

I get the error:

unexpected char: ?

here is an extract from my repository.xml file

            <class-descriptor
             class="com.novobase.jaxbjdo.Minimol"
             table="minimol">

      <field-descriptor id="1"
         name="id"
         column="ID"
         jdbc-type="INTEGER"
         primarykey="true"
         autoincrement="true"/>

      <field-descriptor id="2"
         name="name"
         column="NAME"
         jdbc-type="VARCHAR"/>
...
   </class-descriptor>


What format should I use for such a simple OQL query?

Thanks
Neil






--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>






--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to