RE: OQLQuery
OQL queries are different from sql. You need to do something more like: query.create("select ANYTHING from " + YOURCLASS.class.getName() +" where id=null"); ANYTHING is ignored as far as I can tell so you really can put anything! YOURCLASS is the name of the class you are querying (NOT THE TABLE!!!). I'm not exactly sure of how to check for nulls in OQL, so field=null may not work. Hope this helps, Daniel. -Original Message- From: Rémi Bars [mailto:[EMAIL PROTECTED] Sent: 25 February 2004 11:05 To: OJB Users List Subject: Re: OQLQuery when i put (select * from table where id is null) i got this message : line 1:107: unexpected token: id Remi - Original Message - From: "Rémi Bars" <[EMAIL PROTECTED]> To: "OJB Users List" <[EMAIL PROTECTED]> Sent: Wednesday, February 25, 2004 11:44 AM Subject: OQLQuery > i all i create a oqlQuery like this > > OQLQuery query = odmg.newOQLQuery(); > > // 2. set the OQL select statement > query.create(select * from table where id=null) > > when i try this i got this message : > > line 1:120: unexpected token: null > > what is wrong? > > Thank > > remi > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OQLQuery
when i put (select * from table where id is null) i got this message : line 1:107: unexpected token: id Remi - Original Message - From: "Rémi Bars" <[EMAIL PROTECTED]> To: "OJB Users List" <[EMAIL PROTECTED]> Sent: Wednesday, February 25, 2004 11:44 AM Subject: OQLQuery > i all i create a oqlQuery like this > > OQLQuery query = odmg.newOQLQuery(); > > // 2. set the OQL select statement > query.create(select * from table where id=null) > > when i try this i got this message : > > line 1:120: unexpected token: null > > what is wrong? > > Thank > > remi > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OQLQuery being cached? [orb newbie]
In real, I'm not an specialist in caches ;), but I've used with success tag inside class-descriptor, no elsewhere. I think I've read somewhere that is possible to configure the object-cache for the connection (or the alias), but I never reade more, and now I'm not sure. Give a try to DTD doc. Is the first place I look when in doubt. Best regards, Edson Richter > Thanks for your quick answer, I cheched the OJB.properties file an "I" > was using DefaultCacheImpl I change it to ObjectCacheEmptyImpl and now > it is working as I was expecting. > > Now just to learn the reasons for the previous behaviour: > > A comment in OJB.properties: > # The ObjectCacheClass entry tells OJB which concrete ObjectCache > # implementation is to be used as standard cache. > # Its also possible to override this entry adding object-cache > elements > # on jdbc-connection-descriptor level and > # per class-descriptor in repository file > > In my repository_internal.xml I have the following line: > > > > > Why it wasn't working as I was expecting? > Where is the documentation about the config parameters for the cache > implementations? > > Thanks for your help, > > K. > > > [EMAIL PROTECTED] wrote: > >>Are you working with DefaultCacheImpl or EmptyCacheImpl? >>If you are working with DefaultCacheImpl, take a look at config parameters. >>Otherwise, are there any exceptions (stack trace), messages (they can be very >>usefull if >> you >>enable higher level of logging as DEBUG). >> >>Best regards, >> >>Edson Richter >> >> >> >> > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OQLQuery being cached? [orb newbie]
Thanks for your quick answer, I cheched the OJB.properties file an "I" was using DefaultCacheImpl I change it to ObjectCacheEmptyImpl and now it is working as I was expecting. Now just to learn the reasons for the previous behaviour: A comment in OJB.properties: # The ObjectCacheClass entry tells OJB which concrete ObjectCache # implementation is to be used as standard cache. # Its also possible to override this entry adding object-cache elements # on jdbc-connection-descriptor level and # per class-descriptor in repository file In my repository_internal.xml I have the following line: Why it wasn't working as I was expecting? Where is the documentation about the config parameters for the cache implementations? Thanks for your help, K. [EMAIL PROTECTED] wrote: Are you working with DefaultCacheImpl or EmptyCacheImpl? If you are working with DefaultCacheImpl, take a look at config parameters. Otherwise, are there any exceptions (stack trace), messages (they can be very usefull if you enable higher level of logging as DEBUG). Best regards, Edson Richter - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OQLQuery being cached? [orb newbie]
Are you working with DefaultCacheImpl or EmptyCacheImpl? If you are working with DefaultCacheImpl, take a look at config parameters. Otherwise, are there any exceptions (stack trace), messages (they can be very usefull if you enable higher level of logging as DEBUG). Best regards, Edson Richter > Hi, > > I am executing the following code: > >OQLQuery query = impl.newOQLQuery(); >query.create( [THEQUERY] ); >DList results = (DList)query.execute(); >Iterator iterator = results.iterator(); > > If I change some column with an external tool and then execute the code, > the updated column is not reflected in the orb objects. > > Is there a config value or a runtime parameter that I need to change? > What is going on behind the scenes here? > > Thanks for your help, > > K. > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]