Re: OJB_HL_SEQ

2006-01-21 Thread Dennis Bekkering
I had the same problem and fixed it by removing

  

from

   

in repository_internal.xml

regards,
Dennis


2006/1/21, Armin Waibel <[EMAIL PROTECTED]>:
> Hi Rick,
>
> Rick Roman wrote:
> > After upgrading to ojb-1.0.4 I am getting an error:
> >
> > [org.apache.ojb.broker.metadata.RepositoryXmlHandler] ERROR: Exception
> > while read metadata
> > Error creating PersistentField:
> > org.apache.ojb.broker.util.sequence.HighLowSequence, name
> > org.apache.ojb.broker.metadata.MetadataException: Error creating
> > PersistentField: org.apache.ojb.broker.util.sequence.HighLowSequence, name
> >at
> > org.apache.ojb.broker.metadata.fieldaccess.PersistentFieldFactory.createPersistentField(Unknown
> > Source)
> >at
> > org.apache.ojb.broker.metadata.RepositoryXmlHandler.startElement(Unknown
> > Source)
> >at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown
> > Source)
> >
> > I think I need to do the operation described in the release notes:
> >
> > * Internal used OJB_HL_SEQ table changed. Remove of deprecated column.
> >  If the SequenceManagerHighLowImpl was used and problems occur after
> > upgrade, please
> >  drop and recreate this table without removed column
> >
> > Where is the table and where is the new definition to recreate it with?
> >
>
> Hope this link help:
>
> http://db.apache.org/ojb/docu/guides/platforms.html#OJB+internal+tables
>
> The concrete sql definition depends on the used DB, e.g. hsql:
>
> drop table OJB_HL_SEQ if exists;
>
> CREATE TABLE OJB_HL_SEQ
> (
>  TABLENAME VARCHAR (250),
>  MAX_KEY BIGINT,
>  GRAB_SIZE integer,
>  VERSION integer,
>  PRIMARY KEY(TABLENAME)
> );
>
> regards,
> Armin
>
>
> >
> >
> > -
> > 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]
>
>


--
mvg,
Dennis

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



Re: exception in JDBC driver

2006-01-21 Thread Armin Waibel

Armin Waibel wrote:

Hi Sergey,

Manukyan, Sergey wrote:


Hi Everybody,

We upgraded to 1.0.4 and using JT400-4.4 JDBC driver for AS400 data
source.

See now our JDBC driver throwing exceptions when OJB askes him for field
named "OJB_CLAZZ", that the result set doesn't have, and it happens for
every row.

Is it possible to avoid OJB to check for this field from result set?



First, thanks much! This was an important hint to unravel the mystery of 
slowdown of query performance between 1.0.3 and 1.0.4.


Currently OJB checks each row of a result set for this column. The check 
was needed to resolve real class names when inheritance was used.
http://db.apache.org/ojb/docu/guides/advanced-technique.html#Mapping+Each+Subclass+to+a+Distinct+Table+%28table+per+subclass%29 



I will check in a improved version tomorrow. This version will only ask 
for the column when it really exists, thus no exceptions should occur.




It's fixed in SVN OJB_1_0_RELEASE branch.

regards,
Armin



regards,
Armin



-Sergey






-Original Message-
From: Armin Waibel [mailto:[EMAIL PROTECTED] Sent: Friday, January 
20, 2006 12:58 PM

To: OJB Users List
Subject: Re: store object without references

Hi Sergey,

Manukyan, Sergey wrote:


Folks,

I am using 1.0.4.

Could you please advice if there is a way to store an object of some
class without storing references although I defined in the descriptor



of


the class to store references as well.

I am looking for a workaround that will enable me to do it in some
cases...

Something like:

PersistenceBroker.store(object, )




you can use a method defined in PersistenceBrokerInternal, simply cast 
the used PB instance to PBI.


public void store(Object obj, Identity oid, ClassDescriptor cld, 
boolean insert, boolean ignoreReferences)
This method will ignore the auto-update settings when flag 
'ignoreReferences' is true.


http://db.apache.org/ojb/api/org/apache/ojb/broker/PersistenceBrokerInte
rnal.html

Build the Identity via IdentityFactory (service method in PB), lookup 
the ClassDescriptor via PB.


regards,
Armin




Thank you,

Sergey

**
** LEGAL DISCLAIMER **
**

This E-mail message and any attachments may contain

legally privileged, confidential or proprietary

information. If you are not the intended recipient(s),
or the employee or agent responsible for delivery of

this message to the intended recipient(s), you are

hereby notified that any dissemination, distribution

or copying of this E-mail message is strictly

prohibited. If you have received this message in

error, please immediately notify the sender and

delete this E-mail message from your computer.

-
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]




-
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]