Persistence by reachability with FK in PK

Hi,
     I have a question concerning persistence-by-reachability in the
following scenario (also see code, log in attachment):
+ A composite aggregation between Attribute and AttributeType (Attribute
cannot be created without a valid Type) is mapped to the following schema:
CREATE TABLE ATTRIBUTE_TYPE (
ID NUMBER (4) NOT NULL,
TYPE NUMBER (2) NOT NULL,
CONSTRAINT ATTRIBUTE_TYPE_PK
PRIMARY KEY ( ID ) ) ;
CREATE TABLE ATTRIBUTE (
CLASS_ID NUMBER(4) NOT NULL,
TYPE_ID NUMBER (4) NOT NULL,
VALUE VARCHAR2 (100) NOT NULL,
CONSTRAINT ATTRIBUTE_PK
PRIMARY KEY ( CLASS_ID, TYPE_ID ) ) ;
ALTER TABLE ATTRIBUTE ADD CONSTRAINT ATTRIBUTE_FK
FOREIGN KEY (TYPE_ID)
REFERENCES ATTRIBUTE_TYPE (ID) ;
+ In the constructor of Attribute, the AttributeType is given as
parameter and both the instance variable type as typeId is set (and
type.getId() == typeId). Both classes use Application Identity.
private AttributeType type;
private int typeId;
private String value;
private int classId;
public Attribute(int pClassId, AttributeType pType, String pValue) {
     this.classId = pClassId;
     this.typeId = pType.getId();
     this.type = pType;
     this.value = pValue;
+ So, when persisting a new instance of Attribute of a new AttributeType
the ATTRIBUTE_FK constraint is violated:
javax.jdo.PersistentManager pm = ...
pm.currentTransaction().begin();
pm.makePersistent(new Attribute(10,new AttributeType(50,10),"KODO")));
pm.currentTransaction().commit();
According to the JDO Specification AttributeType is part of the object
closure of Attribute and is marked provisionally persistent by the
'Persistence-by-reachability' algorithm and made persistent at commit.
Apparently KODO doesn't take the FK constraint into account to derive
the order in which to make classes persistent. Is this assumption
correct? And is there a workaround for this?
Thanks in advance,
Stijn Van den Enden

Assuming we're talking about Oracle, using deferred constraints has the
undesirable effect of forcing use of a non-unique index to enforce the FK
constraint.
Is there any other way with 2.5.5 to get Kodo to insert to the parent table,
and delete from the child tables first ?
Regards,
Chris.
"Stijn Van den Enden" <[email protected]> wrote in message
news:[email protected]...
Hi,
thanks a lot!
Marking the FK constraint as Defferable works fine for me.
ALTER TABLE ATTRIBUTE ADD CONSTRAINT ATTRIBUTE_FK
FOREIGN KEY (TYPE_ID)
REFERENCES ATTRIBUTE_TYPE (ID)
DEFERRABLE INITIALLY DEFERRED;
Thanx,
Stijn Van den Enden
Stephen Kim wrote:
Kodo 2.5.x does not do foreign key constraint analysis. You should
either use deferred database constraints (supported on several dbs) or
try using Kodo 3 (in RC stage) which can optionally do so (it is
disabled by default since it could have performance impact (analyzing
instead of simply executing SQL)).
Stijn Van den Enden wrote:
Hi,
I have a question concerning persistence-by-reachability in the
following scenario (also see code, log in attachment):
+ A composite aggregation between Attribute and AttributeType
(Attribute cannot be created without a valid Type) is mapped to the
following schema:
CREATE TABLE ATTRIBUTE_TYPE (
ID NUMBER (4) NOT NULL,
TYPE NUMBER (2) NOT NULL,
CONSTRAINT ATTRIBUTE_TYPE_PK
PRIMARY KEY ( ID ) ) ;
CREATE TABLE ATTRIBUTE (
CLASS_ID NUMBER(4) NOT NULL,
TYPE_ID NUMBER (4) NOT NULL,
VALUE VARCHAR2 (100) NOT NULL,
CONSTRAINT ATTRIBUTE_PK
PRIMARY KEY ( CLASS_ID, TYPE_ID ) ) ;
ALTER TABLE ATTRIBUTE ADD CONSTRAINT ATTRIBUTE_FK
FOREIGN KEY (TYPE_ID)
REFERENCES ATTRIBUTE_TYPE (ID) ;
+ In the constructor of Attribute, the AttributeType is given as
parameter and both the instance variable type as typeId is set (and
type.getId() == typeId). Both classes use Application Identity.
private AttributeType type;
private int typeId;
private String value;
private int classId;
public Attribute(int pClassId, AttributeType pType, String pValue) {
this.classId = pClassId;
this.typeId = pType.getId();
this.type = pType;
this.value = pValue;
+ So, when persisting a new instance of Attribute of a new
AttributeType the ATTRIBUTE_FK constraint is violated:
javax.jdo.PersistentManager pm = ...
pm.currentTransaction().begin();
pm.makePersistent(new Attribute(10,new AttributeType(50,10),"KODO")));
pm.currentTransaction().commit();
According to the JDO Specification AttributeType is part of the object
closure of Attribute and is marked provisionally persistent by the
'Persistence-by-reachability' algorithm and made persistent at commit.
Apparently KODO doesn't take the FK constraint into account to derive
the order in which to make classes persistent. Is this assumption
correct? And is there a workaround for this?
Thanks in advance,
Stijn Van den Enden
DEBUG [main] (JDBCPersistenceManagerFactory.java:241) -
[email protected]b9:
setup
DEBUG [main] (JDBCPersistenceManagerFactory.java:241) -
[email protected]b9:
setup
INFO [main] (LicenseChecker.java:162) - Starting Kodo JDO version
2.5.4 (kodojdo-2.5.4-20031001-1134) with capabilities: [Enterprise
Edition Features, Standard Edition Features, Lite Edition Features,
Evaluation License, Query Extensions, Performance Pack, Statement
Batching, Global Transactions, Developer Tools, Custom Database
Dictionaries, Enterprise Databases, Custom ClassMappings, Custom
ResultObjectProviders, Datacache Plug-in]
INFO [main] (LicenseChecker.java:162) - Starting Kodo JDO version
2.5.4 (kodojdo-2.5.4-20031001-1134) with capabilities: [Enterprise
Edition Features, Standard Edition Features, Lite Edition Features,
Evaluation License, Query Extensions, Performance Pack, Statement
Batching, Global Transactions, Developer Tools, Custom Database
Dictionaries, Enterprise Databases, Custom ClassMappings, Custom
ResultObjectProviders, Datacache Plug-in]
WARN [main] (LicenseChecker.java:181) - WARNING: Kodo JDO Evaluation
expires in 8 days. Please contact [email protected] for
information on extending your evaluation period or purchasing a
license.
WARN [main] (LicenseChecker.java:181) - WARNING: Kodo JDO Evaluation
expires in 8 days. Please contact [email protected] for
information on extending your evaluation period or purchasing alicense.
DEBUG [main] (JDBCPersistenceManagerFactory.java:444) -
[email protected]b9:
registering 1 classes: [class reachability.AttributeType]
DEBUG [main] (JDBCPersistenceManagerFactory.java:444) -
[email protected]b9:
registering 1 classes: [class reachability.AttributeType]
DEBUG [main] (MetaDataParser.java:136) - found JDO resource
package.jdo for reachability.AttributeType at
file:/F:/Sources/Projects/Bugs/jdo/kodo/reachability/package.jdo
DEBUG [main] (MetaDataParser.java:136) - found JDO resource
package.jdo for reachability.AttributeType at
file:/F:/Sources/Projects/Bugs/jdo/kodo/reachability/package.jdo
INFO [main] (JDOMetaDataParser.java:89) -
com.solarmetric.kodo.meta.JDOMetaDataParser@3020ad: parsing source:
file:/F:/Sources/Projects/Bugs/jdo/kodo/reachability/package.jdo
INFO [main] (JDOMetaDataParser.java:89) -
com.solarmetric.kodo.meta.JDOMetaDataParser@3020ad: parsing source:
file:/F:/Sources/Projects/Bugs/jdo/kodo/reachability/package.jdo
DEBUG [main] (MetaDataParser.java:204) - parsed
file:/F:/Sources/Projects/Bugs/jdo/kodo/reachability/package.jdo:
[com.solarmetric.kodo.meta.ClassMetaData@2200d5[;type=class
reachability.Attribute;loader=sun.misc.Launcher$AppClassLoader@12f6684;finis
hed=false;enhanced=false],
com.solarmetric.kodo.meta.ClassMetaData@64ab4d[;type=class
reachability.AttributeType;loader=sun.misc.Launcher$AppClassLoader@12f6684;f
inished=false;enhanced=true]]
>>>
DEBUG [main] (MetaDataParser.java:204) - parsed
file:/F:/Sources/Projects/Bugs/jdo/kodo/reachability/package.jdo:
[com.solarmetric.kodo.meta.ClassMetaData@2200d5[;type=class
reachability.Attribute;loader=sun.misc.Launcher$AppClassLoader@12f6684;finis
hed=false;enhanced=false],
com.solarmetric.kodo.meta.ClassMetaData@64ab4d[;type=class
reachability.AttributeType;loader=sun.misc.Launcher$AppClassLoader@12f6684;f
inished=false;enhanced=true]]
>>>
DEBUG [main] (ClassMetaData.java:305) - parsed metadata: type=class
reachability.AttributeType@110003;validate=true:
[com.solarmetric.kodo.meta.ClassMetaData@2200d5[;type=class
reachability.Attribute;loader=sun.misc.Launcher$AppClassLoader@12f6684;finis
hed=false;enhanced=false],
com.solarmetric.kodo.meta.ClassMetaData@64ab4d[;type=class
reachability.AttributeType;loader=sun.misc.Launcher$AppClassLoader@12f6684;f
inished=false;enhanced=true]]
>>>
DEBUG [main] (ClassMetaData.java:305) - parsed metadata: type=class
reachability.AttributeType@110003;validate=true:
[com.solarmetric.kodo.meta.ClassMetaData@2200d5[;type=class
reachability.Attribute;loader=sun.misc.Launcher$AppClassLoader@12f6684;finis
hed=false;enhanced=false],
com.solarmetric.kodo.meta.ClassMetaData@64ab4d[;type=class
reachability.AttributeType;loader=sun.misc.Launcher$AppClassLoader@12f6684;f
inished=false;enhanced=true]]
>>>
DEBUG [main] (ClassMetaData.java:327) - cached metadata:
type=reachability.Attribute@49d67c;loader=com.solarmetric.kodo.util.MultiLoa
derClassResolver@12f66a3
loaders: [sun.misc.Launcher$AppClassLoader@12f6684]; thread's context
class loader: sun.misc.Launcher$AppClassLoader@12f6684;validate=true:
com.solarmetric.kodo.meta.ClassMetaData@2200d5[;type=class
reachability.Attribute;loader=sun.misc.Launcher$AppClassLoader@12f6684;finis
hed=false;enhanced=false]
>>>
DEBUG [main] (ClassMetaData.java:327) - cached metadata:
type=reachability.Attribute@49d67c;loader=com.solarmetric.kodo.util.MultiLoa
derClassResolver@12f66a3
loaders: [sun.misc.Launcher$AppClassLoader@12f6684]; thread's context
class loader: sun.misc.Launcher$AppClassLoader@12f6684;validate=true:
com.solarmetric.kodo.meta.ClassMetaData@2200d5[;type=class
reachability.Attribute;loader=sun.misc.Launcher$AppClassLoader@12f6684;finis
hed=false;enhanced=false]
>>>
DEBUG [main] (ClassMetaData.java:327) - cached metadata:
type=reachability.AttributeType@110003;loader=com.solarmetric.kodo.util.Mult
iLoaderClassResolver@12f66a3
loaders: [sun.misc.Launcher$AppClassLoader@12f6684]; thread's context
class loader: sun.misc.Launcher$AppClassLoader@12f6684;validate=true:
com.solarmetric.kodo.meta.ClassMetaData@64ab4d[;type=class
reachability.AttributeType;loader=sun.misc.Launcher$AppClassLoader@12f6684;f
inished=false;enhanced=true]
>>>
DEBUG [main] (ClassMetaData.java:327) - cached metadata:
type=reachability.AttributeType@110003;loader=com.solarmetric.kodo.util.Mult
iLoaderClassResolver@12f66a3
loaders: [sun.misc.Launcher$AppClassLoader@12f6684]; thread's context
class loader: sun.misc.Launcher$AppClassLoader@12f6684;validate=true:
com.solarmetric.kodo.meta.ClassMetaData@64ab4d[;type=class
reachability.AttributeType;loader=sun.misc.Launcher$AppClassLoader@12f6684;f
inished=false;enhanced=true]
>>>
DEBUG [main] (ClassMetaData.java:305) - parsed metadata: type=class
java.lang.Object@16fd0b7;validate=true: []
DEBUG [main] (ClassMetaData.java:305) - parsed metadata: type=class
java.lang.Object@16fd0b7;validate=true: []
DEBUG [main] (ClassMetaData.java:344) - created metadata:
type=java.lang.Object@16fd0b7;loader=com.solarmetric.kodo.util.MultiLoaderCl
assResolver@12f66a3
loaders: [sun.misc.Launcher$AppClassLoader@12f6684]; thread's context
class loader: sun.misc.Launcher$AppClassLoader@12f6684;validate=true:
null
DEBUG [main] (ClassMetaData.java:344) - created metadata:
type=java.lang.Object@16fd0b7;loader=com.solarmetric.kodo.util.MultiLoaderCl
assResolver@12f66a3
loaders: [sun.misc.Launcher$AppClassLoader@12f6684]; thread's context
class loader: sun.misc.Launcher$AppClassLoader@12f6684;validate=true:
null
DEBUG [main] (ClassMetaData.java:344) - created metadata:
type=reachability.AttributeType@110003;loader=com.solarmetric.kodo.util.Mult
iLoaderClassResolver@12f66a3
loaders: [sun.misc.Launcher$AppClassLoader@12f6684]; thread's context
class loader: sun.misc.Launcher$AppClassLoader@12f6684;validate=true:
com.solarmetric.kodo.meta.ClassMetaData@64ab4d[;type=class
reachability.AttributeType;loader=sun.misc.Launcher$AppClassLoader@12f6684;f
inished=true;enhanced=true]
>>>
DEBUG [main] (ClassMetaData.java:344) - created metadata:
type=reachability.AttributeType@110003;loader=com.solarmetric.kodo.util.Mult
iLoaderClassResolver@12f66a3
loaders: [sun.misc.Launcher$AppClassLoader@12f6684]; thread's context
class loader: sun.misc.Launcher$AppClassLoader@12f6684;validate=true:
com.solarmetric.kodo.meta.ClassMetaData@64ab4d[;type=class
reachability.AttributeType;loader=sun.misc.Launcher$AppClassLoader@12f6684;f
inished=true;enhanced=true]
>>>
DEBUG [main] (DataSourceImpl.java:323) - [ C:5896993; T:24537094;
D:10973446 ] open: jdbc:oracle:thin:@SUNFIRE:1521:CCLDEV (CCLJDO)
DEBUG [main] (DataSourceImpl.java:323) - [ C:5896993; T:24537094;
D:10973446 ] open: jdbc:oracle:thin:@SUNFIRE:1521:CCLDEV (CCLJDO)
DEBUG [main] (DataSourceImpl.java:323) - [ C:5896993; T:24537094;
D:10973446 ] close:
com.solarmetric.datasource.PoolConnection@59fb21[identityHashCode:8499707,wr
apped:com.solarmetric.datasource.PreparedStatementCache$CacheAwareConnection
@59fb21[identityHashCode:13359904,wrapped:oracle.jdbc.driver.OracleConnectio
n@59fb21]:
>>>
[requests=0;size=0;max=70;hits=0;created=0;redundant=0;overflow=0;new=0;leak
ed=0;unavailable=0]]
>>>
DEBUG [main] (DataSourceImpl.java:323) - [ C:5896993; T:24537094;
D:10973446 ] close:
com.solarmetric.datasource.PoolConnection@59fb21[identityHashCode:8499707,wr
apped:com.solarmetric.datasource.PreparedStatementCache$CacheAwareConnection
@59fb21[identityHashCode:13359904,wrapped:oracle.jdbc.driver.OracleConnectio
n@59fb21]:
>>>
[requests=0;size=0;max=70;hits=0;created=0;redundant=0;overflow=0;new=0;leak
ed=0;unavailable=0]]
>>>
DEBUG [main] (DataSourceImpl.java:323) - [ C:5896993; T:24537094;
D:10973446 ] close connection
DEBUG [main] (DataSourceImpl.java:323) - [ C:5896993; T:24537094;
D:10973446 ] close connection
INFO [main] (DBDictionaryFactory.java:402) - Using dictionary class
"com.solarmetric.kodo.impl.jdbc.schema.dict.OracleDictionary" to
connect to "Oracle" (version "Oracle8i Enterprise Edition Release
8.1.7.0.0 - 64bit Production
With the Partitioning option
JServer Release 8.1.7.0.0 - 64bit Production") with JDBC driver
"Oracle JDBC driver" (version "9.2.0.1.0")
INFO [main] (DBDictionaryFactory.java:402) - Using dictionary class
"com.solarmetric.kodo.impl.jdbc.schema.dict.OracleDictionary" to
connect to "Oracle" (version "Oracle8i Enterprise Edition Release
8.1.7.0.0 - 64bit Production
With the Partitioning option
JServer Release 8.1.7.0.0 - 64bit Production") with JDBC driver
"Oracle JDBC driver" (version "9.2.0.1.0")
DEBUG [main] (JDBCPersistenceManagerFactory.java:345) -
[email protected]b9:
registerClass: reachability.AttributeType@110003=>true
DEBUG [main] (JDBCPersistenceManagerFactory.java:345) -
[email protected]b9:
registerClass: reachability.AttributeType@110003=>true
DEBUG [main] (JDBCPersistenceManagerFactory.java:444) -
[email protected]b9:
registering 2 classes: [class reachability.AttributeType, class
reachability.Attribute]
DEBUG [main] (JDBCPersistenceManagerFactory.java:444) -
[email protected]b9:
registering 2 classes: [class reachability.AttributeType, class
reachability.Attribute]
DEBUG [main] (JDBCPersistenceManagerFactory.java:345) -
[email protected]b9:
registerClass: reachability.Attribute@49d67c=>true
DEBUG [main] (JDBCPersistenceManagerFactory.java:345) -
[email protected]b9:
registerClass: reachability.Attribute@49d67c=>true
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] open: jdbc:oracle:thin:@SUNFIRE:1521:CCLDEV (CCLJDO)
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] open: jdbc:oracle:thin:@SUNFIRE:1521:CCLDEV (CCLJDO)
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] preparing statement <11544872>: SELECT SYSDATE FROM DUAL
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] preparing statement <11544872>: SELECT SYSDATE FROM DUAL
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] executing statement <11544872>: (SELECT SYSDATE FROM
DUAL): [reused=1;params={}]
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] executing statement <11544872>: (SELECT SYSDATE FROM
DUAL): [reused=1;params={}]
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] preparing statement <24880015>: INSERT INTO
ATTRIBUTE(CLASS_ID, TYPE_ID, VALUE) VALUES (?, ?, ?)
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] preparing statement <24880015>: INSERT INTO
ATTRIBUTE(CLASS_ID, TYPE_ID, VALUE) VALUES (?, ?, ?)
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] executing statement <24880015>: (INSERT INTO
ATTRIBUTE(CLASS_ID, TYPE_ID, VALUE) VALUES (?, ?, ?)):
[reused=1;params={(int)10,(int)10,(String)KODO}]
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] executing statement <24880015>: (INSERT INTO
ATTRIBUTE(CLASS_ID, TYPE_ID, VALUE) VALUES (?, ?, ?)):
[reused=1;params={(int)10,(int)10,(String)KODO}]
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] begin rollback
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] begin rollback
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] end rollback 0ms
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] end rollback 0ms
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] close:
com.solarmetric.datasource.PoolConnection@69d02b[identityHashCode:6151022,wr
apped:com.solarmetric.datasource.PreparedStatementCache$CacheAwareConnection
@69d02b[identityHashCode:32580443,wrapped:oracle.jdbc.driver.OracleConnectio
n@69d02b]:
>>>
[requests=2;size=2;max=70;hits=0;created=2;redundant=0;overflow=0;new=2;leak
ed=0;unavailable=0]]
>>>
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] close:
com.solarmetric.datasource.PoolConnection@69d02b[identityHashCode:6151022,wr
apped:com.solarmetric.datasource.PreparedStatementCache$CacheAwareConnection
@69d02b[identityHashCode:32580443,wrapped:oracle.jdbc.driver.OracleConnectio
n@69d02b]:
>>>
[requests=2;size=2;max=70;hits=0;created=2;redundant=0;overflow=0;new=2;leak
ed=0;unavailable=0]]
>>>
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] close connection
DEBUG [main] (DataSourceImpl.java:323) - [ C:6934571; T:24537094;
D:10973446 ] close connection
DEBUG [main] (PersistenceManagerImpl.java:481) - An exception occurred
while ending a transaction. This exception will be thrown. It is being
logged here for informational purposes only.
com.solarmetric.kodo.runtime.FatalDataStoreException:
com.solarmetric.kodo.impl.jdbc.sql.SQLExceptionWrapper: [SQL=INSERT
INTO ATTRIBUTE(CLASS_ID, TYPE_ID, VALUE) VALUES (10, 10, 'KODO')]
[PRE=INSERT INTO ATTRIBUTE(CLASS_ID, TYPE_ID, VALUE) VALUES (?, ?, ?)]
ORA-02291: integrity constraint (CCLJDO.ATTRIBUTE_FK) violated -
parent key not found
[code=2291;state=23000]
NestedThrowables:
com.solarmetric.kodo.impl.jdbc.sql.SQLExceptionWrapper: [SQL=INSERT
INTO ATTRIBUTE(CLASS_ID, TYPE_ID, VALUE) VALUES (10, 10, 'KODO')]
[PRE=INSERT INTO ATTRIBUTE(CLASS_ID, TYPE_ID, VALUE) VALUES (?, ?, ?)]
ORA-02291: integrity constraint (CCLJDO.ATTRIBUTE_FK) violated -
parent key not found
at
com.solarmetric.kodo.impl.jdbc.runtime.SQLExceptions.throwFatal(SQLException
s.java:58)
>>>
at
com.solarmetric.kodo.impl.jdbc.runtime.JDBCStoreManager.flush(JDBCStoreManag
er.java:559)
>>>
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.flushInternal(Persistenc
eManagerImpl.java:697)
>>>
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.commit(PersistenceManage
rImpl.java:422)
>>>
at
reachabilicom.solarmetric.kodo.runtime.FatalDataStoreException:
com.solarmetric.kodo.impl.jdbc.sql.SQLExceptionWrapper: [SQL=INSERT
INTO ATTRIBUTE(CLASS_ID, TYPE_ID, VALUE) VALUES (10, 10, 'KODO')]
[PRE=INSERT INTO ATTRIBUTE(CLASS_ID, TYPE_ID, VALUE) VALUES (?,
ty.Main.main(Main.java:26)
NestedThrowablesStackTrace:
java.sql.SQLException: ORA-02291: integrity constraint
(CCLJDO.ATTRIBUTE_FK) violated - parent key not found
at
oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java:289)
at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:573)
atoracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1891)> >>         at> >> oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:1093)> >>         at> >>oracle.jdbc.driver.OracleStatement.executeNonQuery(OracleStatement.java:2047)> >>> >>         at> >>oracle.jdbc.driver.OracleStatement.doExecuteOther(OracleStatement.java:1940)> >>> >>         at> >>oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:2709)> >>> >>         at> >>oracle.jdbc.driver.OraclePreparedStatement.doScrollPstmtExecuteUpdate(OraclePreparedStatement.java:3975)> >>> >>         at> >>oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:623)> >>> >>         at> >>com.solarmetric.datasource.PreparedStatementWrapper.executeUpdate(PreparedStatementWrapper.java:111)> >>> >>         at> >>com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.executePreparedStatementNonBatch(SQLExecutionManagerImpl.java:454)> >>> >>         at> >>com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.executePreparedStatement(SQLExecutio?,> >> ?)
ORA-02291: integrity constraint (CCLJDO.ATTRIBUTE_FK) violated -
parent key not found
[code=2291;state=23000]
NestedThrowables:
com.solarmetric.kodo.impl.jdbc.sql.SQLExceptionWrapper: [SQL=INSERT
INTO ATTRIBUTE(CLASS_ID, TYPE_ID, VALUE) VALUES (nManagerImpl.java:423)
at
com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.executeInternal(SQLEx
ecutionManagerImpl.java:381)
>>>
at
com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.flush(SQLExecutionMan
agerImpl.java:255)
>>>
at
com.solarmetric.kodo.impl.jdbc.runtime.JDBCStoreManager.flush(JDBCStoreManag
er.java:554)
>>>
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.flushInternal(Persistenc
eManagerImpl.java:697)
>>>
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.commit(PersistenceManage
rImpl.java:422)
>>>
at reachability.Main.main(Main.java:26)
DEBUG [main] (PersistenceManagerImpl.java:481) - An exception occurred
while ending a transaction. This exception will be thrown. It is being
logged here for informational purposes only.
com.solar10, 10, 'KODO')] [PRE=INSERT INTO ATTRIBUTE(CLASS_ID,
TYPE_ID, VALUE) VALUES (?, ?, ?)]
ORA-02291: integrity constraint (CCLJDO.ATTRIBUTE_FK) violated -
parent key not found
at
com.solarmetric.kodo.impl.jdbc.runtime.SQLExceptions.throwFatal(SQLExceptmet
ric.kodo.runtime.FatalDataStoreException:
com.solarmetric.kodo.impl.jdbc.sql.SQLExceptionWrapper: [SQL=INSERT
INTO ATTRIBUTE(CLASS_ID, TYPE_ID, VALUE) VALUES (10, 10, 'KODO')]
[PRE=INSERT INTO ATTRIBUTE(CLASS_ID, TYPE_ID, VALUE) VALUES (?, ?, ?)]
ORA-02291: integrity constraint (CCLJDO.ATTRIBUTE_FK) violated -
parent key not found
[code=2291;state=23000]
NestedThrowables:
com.solarmetric.kodo.impl.jdbc.sql.SQLExceptionWrapper: [SQL=INSERT
INTO ATTRIBUTE(CLASS_ID, TYPE_ID, VALUE) VALUES (10, 10, 'KODO')]
[PRE=INSERT INTO ATTRIBUTE(CLASS_ID, TYPE_ID, VALUE) VALUES (?, ?, ?)]
ORA-02291: integrity constraint (CCLJDO.ATTRIBUTE_FK) violated -
parent key not found
at
com.solarmetric.kodo.impl.jdbc.runtime.SQLExceptions.throwFatal(SQLException
s.java:58)
>>>
at
com.solarmetric.kodo.impl.jdbc.runtime.JDBCStoreManager.flush(JDBCStoreManag
er.java:559)
>>>
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.flushInternal(Persistenc
eManagerImpl.java:697)
>>>
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.commit(PersistenceManage
rImpl.java:422)
>>>
at reachability.Main.main(Main.java:26)
NestedThrowablesStackTrace:
java.sql.SQLException: ORA-02291: integrity constraint
(CCLJDO.ATTRIBUTE_FK) violated - parent key not found
at oracle.jdbc.dbaccess.DBErions.java:58)
at
com.solarmetric.kodo.impl.jdbc.runtime.JDBCStoreManager.flush(JDBCStoreManag
er.java:559)
>>>
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.flushInternal(Persistenc
eManagerImpl.java:697)
>>>
at
com.solarmetric.kodo.runtime.Persistencror.throwSqlException(DBError.java:13
4)
>>>
at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java:289)
at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:573)
atoracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1891)
at
oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:1093)
at
oracle.jdbc.driver.OracleStatement.executeNonQuery(OracleStatement.java:2047
>>>
at
oracle.jdbc.driver.OracleStatement.doExecuteOther(OracleStatement.java:1940)
>>>
at
oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java
:2709)
>>>
at
oracle.jdbc.driver.OraclePreparedStatement.doScrollPstmtExecuteUpdate(Oracle
PreparedStatement.java:3975)
>>>
at
oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedState
ment.java:623)
>>>
at
com.solarmetric.datasource.PreparedStatementWrapper.executeUpdate(PreparedSt
atementWrapper.java:111)
>>>
at
com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.executePreparedStatem
entNonBatch(SQLExecutionManagerImpl.java:454)
>>>
at
com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.executePreparedStatem
ent(SQLExecutionManagerImpl.java:423)
>>>
at
com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.executeInternal(SQLEx
ecutionManagerImpl.java:381)
>>>
at
com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.flush(SQLExecutionMan
agerImpl.java:255)
>>>
at
com.solarmetric.kodo.impl.jdbc.runtime.JDBCStoreManager.flush(JDBCStoreManag
er.java:554)
>>>
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.flushInternal(Persistenc
eManagerImpl.java:697)
>>>
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.commit(PersistenceManage
rImpl.java:422)
>>>
at reachability.Main.main(Main.java:26)
eManagerImpl.commit(PersistenceManagerImpl.java:422)
at reachability.Main.main(Main.java:26)
NestedThrowablesStackTrace:
java.sql.SQLException: ORA-02291: integrity constraint
(CCLJDO.ATTRIBUTE_FK) violated - parent key not found
at
oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java:289)
at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:573)
atoracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1891)
at
oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:1093)
at
oracle.jdbc.driver.OracleStatement.executeNonQuery(OracleStatement.java:2047
>>>
at
oracle.jdbc.driver.OracleStatement.doExecuteOther(OracleStatement.java:1940)
>>>
at
oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java
:2709)
>>>
at
oracle.jdbc.driver.OraclePreparedStatement.doScrollPstmtExecuteUpdate(Oracle
PreparedStatement.java:3975)
>>>
at
oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedState
ment.java:623)
>>>
at
com.solarmetric.datasource.PreparedStatementWrapper.executeUpdate(PreparedSt
atementWrapper.java:111)
>>>
at
com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.executePreparedStatem
entNonBatch(SQLExecutionManagerImpl.java:454)
>>>
at
com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.executePreparedStatem
ent(SQLExecutionManagerImpl.java:423)
>>>
at
com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.executeInternal(SQLEx
ecutionManagerImpl.java:381)
>>>
at
com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.flush(SQLExecutionMan
agerImpl.java:255)
>>>
at
com.solarmetric.kodo.impl.jdbc.runtime.JDBCStoreManager.flush(JDBCStoreManag
er.java:554)
>>>
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.flushInternal(Persistenc
eManagerImpl.java:697)
>>>
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.commit(PersistenceManage
rImpl.java:422)
>>>
at reachability.Main.main(Main.java:26)
Exception in thread "main" _

Similar Messages

  • Ibm Visual age 3.5 Persistence Name Server with Oracle 8.1.7

    Hello every one!
    Iam facing a problem with visualage 3.5 persistence name server with Oracle DB. I configured PNS with oracle driver (thin driver).
    I could start the pns server, Servlet Engine.
    I loaded my application with PNS and oracle thin driver is not executing any queries.
    Without PNS, directly interacting with Oracle DB thru JDBC also works fine.
    Has anyone tried to use PNS with Oracle successfully?
    Thanks
    Keerthi

    hello there,
    check these things in u r mac before launching PNS..
    1: Is OracleDriver is there in the path i mean in the PNS path..
    2: Right click and check the properties...
    3: and also check the env properties and launch the PNS if PNS is launched then u can work on it...

  • Persistence By reachability issue Application Identity

    When I Persist the base object it tries to create the related objects
    ParamRuleCondition has Collection of ParamRuleConditionExp and
    ParamRuleConditionExp has Collection of ParametricExpValue
    ParamRuleConditionExp has composite Primary Key with two keys
    (ParamRuleCondition , ParametricFeature)
    ParametricExpValue has composite Primary Key with three keys one of them
    (ExpValue) is a String (ParamRuleCondition , ParametricFeature , ExpValue)
    On saving ParamRuleCondition,
    it create ParamRuleCondition and ParamRuelConditionExp properly
    but tries to insert null in ParametricExpValue
    The error is listed at the end
    To define composite primary key for ParamRuleConditionExp
    I have two extra attribute 'Id' and 'paramFeatureId'
    Is this the right way of doing it?
    The Pk were generated using the
    com.solarmetric.kodo.enhance.ApplicationIdTool class
    Thanks for your Help
    -Paresh
    I have the following object hirearchy
    Class RuleCondition {
    private Long Id
    Class ParamRuleCondition extends RuleCondition {
    private Collection paramRuleConditionExps;
    class ParamRuleConditionExp {
    private ParamRuleCondition paramRuleCondition;
    private Long id;
    private ParametricFeature parametricFeature;
    private Long paramFeatureId;
    private Collection expressionValues;
    Class ParametricFeature {
    private Long paramFeatureId;
    private String parametricFeatureCode;
    Class ParametricExpValue {
    private String expValue;
    private ParamRuleConditionExp paramRuleCondExp;
    private Long id;
    private Long paramFeatureId;
    The system.jdo is as follows
    <jdo>
    <package name="com.paresh">
    <class
    objectid-class="com.international.core.pk.RuleConditionPK"
    identity-type="application" name="RuleCondition">
    <field name="id" primary-key="true">
    <extension key="data-column" value="RULE_COND_ID"
    vendor-name="kodo"/>
    </field>
    <extension key="class-column" value="TYPE" vendor-name="kodo"/>
    <extension key="subclass-provider"
    value="com.solarmetric.kodo.impl.jdbc.ormapping.IntegerSubclassProvider"
    vendor-name="kodo"/>
    <extension key="subclass-indicator-value" value="0"
    vendor-name="kodo"/>
    <extension key="table" value="RULE_CONDITION"
    vendor-name="kodo"/>
    <extension key="lock-column" value="none" vendor-name="kodo"/>
    </class>
    <class identity-type="application" name="ParamRuleCondition"
    persistence-capable-superclass="RuleCondition">
    <field name="paramRuleConditionExp">
    <collection element-type="ParamRuleConditionExp"/>
    <extension key="inverse" value="paramRuleCondition"
    vendor-name="kodo"/>
    </field>
    <extension key="subclass-indicator-value" value="3"
    vendor-name="kodo"/>
    <extension key="table" value="RULE_CONDITION"
    vendor-name="kodo"/>
    <extension key="lock-column" value="none" vendor-name="kodo"/>
    </class>
    <class
    objectid-class="com.international.core.pk.ParamRuleConditionExpPK"
    identity-type="application" name="ParamRuleConditionExp">
    <field name="id" primary-key="true">
    <extension key="data-column" value="RULE_COND_ID"
    vendor-name="kodo"/>
    </field>
    <field name="paramRuleCondition">
    <extension key="id-data-column" value="RULE_COND_ID"
    vendor-name="kodo"/>
    </field>
    <field name="paramFeatureId" primary-key="true">
    <extension key="data-column" value="PARAM_FETR_ID"
    vendor-name="kodo"/>
    </field>
    <field name="parametricFeature">
    <extension key="paramFeatureId-data-column"
    value="PARAM_FETR_ID" vendor-name="kodo"/>
    </field>
    <field name="expressionValues">
    <collection element-type="ParametricExpValue"/>
    <extension key="inverse" value="paramRuleCondExp"
    vendor-name="kodo"/>
    </field>
    <extension key="class-column" value="none" vendor-name="kodo"/>
    <extension key="table" value="PARAM_RULE_CONDITION_EXP"
    vendor-name="kodo"/>
    <extension key="lock-column" value="none" vendor-name="kodo"/>
    </class>
    <class
    objectid-class="com.international.core.pk.ParametricFeaturePK"
    identity-type="application" name="ParametricFeature">
    <field name="paramFeatureId" primary-key="true">
    <extension key="data-column" value="PARAM_FETR_ID"
    vendor-name="kodo"/>
    </field>
    <field name="parametricFeatureCode">
    <extension key="data-column" value="PARAM_FETR_CD"
    vendor-name="kodo"/>
    </field>
    <extension key="class-column" value="none" vendor-name="kodo"/>
    <extension key="table" value="PARAMETRIC_FEATURE"
    vendor-name="kodo"/>
    <extension key="lock-column" value="none" vendor-name="kodo"/>
    </class>
    <class
    objectid-class="com.international.core.pk.ParametricExpValuePK"
    identity-type="application" name="ParametricExpValue">
    <field name="expValue" primary-key="true">
    <extension key="data-column" value="EXP_VAL"
    vendor-name="kodo"/>
    </field>
    <field name="id" primary-key="true">
    <extension key="data-column" value="RULE_COND_ID"
    vendor-name="kodo"/>
    </field>
    <field name="paramFeatureId" primary-key="true">
    <extension key="data-column" value="PARAM_FETR_ID"
    vendor-name="kodo"/>
    </field>
    <field name="paramRuleCondExp">
    <extension key="id-data-column" value="RULE_COND_ID"
    vendor-name="kodo"/>
    <extension key="paramFeatureId-data-column"
    value="PARAM_FETR_ID" vendor-name="kodo"/>
    </field>
    <extension key="class-column" value="none" vendor-name="kodo"/>
    <extension key="table" value="PARAMETRIC_EXP_VALUE"
    vendor-name="kodo"/>
    <extension key="lock-column" value="none" vendor-name="kodo"/>
    </class>
    </jdo>
    </package>
    THe error is something like
    [9/25/03 10:42:12:797 GMT+05:30] 44501d6f ExceptionUtil E CNTR0020E:
    Non-application exception occurred while processing method
    "createParamRuleCondition" on bean
    "BeanId(CdmsDeploy#cdms-ejb.jar#Validation, null)". Exception data:
    com.solarmetric.kodo.runtime.FatalDataStoreException:
    com.solarmetric.kodo.impl.jdbc.sql.SQLExceptionWrapper:
    [SQL=INSERT INTO PARAMETRIC_EXP_VALUE(EXP_VAL, PARAM_FETR_ID,
    RULE_COND_ID) VALUES ('100', null, null)]
    [PRE=INSERT INTO PARAMETRIC_EXP_VALUE(EXP_VAL, PARAM_FETR_ID,
    RULE_COND_ID) VALUES (?, ?, ?)]
    ORA-01400: cannot insert NULL into
    ("PARESH"."PARAMETRIC_EXP_VALUE"."RULE_COND_ID")
    [code=1400;state=23000]

    It sounds like your "PARAMETRIC_EXP_VALUE" table's "RULE_COND_ID" field
    does not allow nulls. Did you create this table? If so, did you
    explicitely disallow nulls from being inserted into the table?Yes nulls are disallowed for column "RULE_COND_ID" as it is part of the
    composite primary key for PARAMETRIC_EXP_VALUE table.
    I don't understand what you mean here. Do you mean that you are trying
    to set the ID "just before it is persisted"? How are you doing this
    (e.g., in the jdoPreStore method)?It is not done in jdoPreStore method.
    I call paramRuleCondition.setId(new Long(<value>))
    just before calling pm.makePersistent(paramRuleCondition)
    Thanks
    -Paresh
    Marc Prud'hommeaux wrote:
    Paresh-
    It sounds like your "PARAMETRIC_EXP_VALUE" table's "RULE_COND_ID" field
    does not allow nulls. Did you create this table? If so, did you
    explicitely disallow nulls from being inserted into the table?
    One thing I would like to add is that ParamRuleCondition's id has a 'null'
    value until just before it is persisted.
    I don't understand what you mean here. Do you mean that you are trying
    to set the ID "just before it is persisted"? How are you doing this
    (e.g., in the jdoPreStore method)?
    In article <[email protected]>, Paresh wrote:
    Thanks for your help Stephen
    I changed the business object method to set the id
    But now I am getting a different error
    The new error is listed below
    One thing I would like to add is that ParamRuleCondition's id has a 'null'
    value until just before it is persisted.
    But even then the Id is propogated to ParamRuleConditionExp, from where I
    would expect it to go to the ParametricExpValue. But it doesn't happen.
    Is my expectation right or is there a gap in my understanding of the way
    KODO works?
    Thanks for your help
    -Paresh
    Exception data: com.solarmetric.kodo.runtime.FatalDataStoreException:
    com.solarmetric.kodo.impl.jdbc.sql.SQLExceptionWrapper:
    [SQL=INSERT INTO PARAMETRIC_EXP_VALUE(EXP_VAL, PARAM_FETR_ID,
    RULE_COND_ID) VALUES ('100', 3, null)]
    [PRE=INSERT INTO PARAMETRIC_EXP_VALUE(EXP_VAL, PARAM_FETR_ID,
    RULE_COND_ID) VALUES (?, ?, ?)]
    ORA-01400: cannot insert NULL into
    ("CDMS2"."PARAMETRIC_EXP_VALUE"."RULE_COND_ID")
    Stephen Kim wrote:
    When attempting to do what you want to do (a persistent class column as
    part of the pk), you have to set both the pk field and the relation.
    i.e. yourClass.setFeatureId (feature.getId ());
    yourClass.setFeature (feature);
    Of course that logic can be encapsulated in your business objects.
    Paresh wrote:
    When I Persist the base object it tries to create the related objects
    ParamRuleCondition has Collection of ParamRuleConditionExp and
    ParamRuleConditionExp has Collection of ParametricExpValue
    ParamRuleConditionExp has composite Primary Key with two keys
    (ParamRuleCondition , ParametricFeature)
    ParametricExpValue has composite Primary Key with three keys one of them
    (ExpValue) is a String (ParamRuleCondition , ParametricFeature ,
    ExpValue)
    >>>>
    On saving ParamRuleCondition,
    it create ParamRuleCondition and ParamRuelConditionExp properly
    but tries to insert null in ParametricExpValue
    The error is listed at the end
    To define composite primary key for ParamRuleConditionExp
    I have two extra attribute 'Id' and 'paramFeatureId'
    Is this the right way of doing it?
    The Pk were generated using the
    com.solarmetric.kodo.enhance.ApplicationIdTool class
    Thanks for your Help
    -Paresh
    I have the following object hirearchy
    Class RuleCondition {
    private Long Id
    Class ParamRuleCondition extends RuleCondition {
    private Collection paramRuleConditionExps;
    class ParamRuleConditionExp {
    private ParamRuleCondition paramRuleCondition;
    private Long id;
    private ParametricFeature parametricFeature;
    private Long paramFeatureId;
    private Collection expressionValues;
    Class ParametricFeature {
    private Long paramFeatureId;
    private String parametricFeatureCode;
    Class ParametricExpValue {
    private String expValue;
    private ParamRuleConditionExp paramRuleCondExp;
    private Long id;
    private Long paramFeatureId;
    The system.jdo is as follows
    <jdo>
    <package name="com.paresh">
    <class
    objectid-class="com.international.core.pk.RuleConditionPK"
    identity-type="application" name="RuleCondition">
    <field name="id" primary-key="true">
    <extension key="data-column" value="RULE_COND_ID"
    vendor-name="kodo"/>
    </field>
    <extension key="class-column" value="TYPE"vendor-name="kodo"/>
    <extension key="subclass-provider"
    value="com.solarmetric.kodo.impl.jdbc.ormapping.IntegerSubclassProvider"
    vendor-name="kodo"/>
    <extension key="subclass-indicator-value" value="0"
    vendor-name="kodo"/>
    <extension key="table" value="RULE_CONDITION"
    vendor-name="kodo"/>
    <extension key="lock-column" value="none"vendor-name="kodo"/>
    </class>
    <class identity-type="application" name="ParamRuleCondition"
    persistence-capable-superclass="RuleCondition">
    <field name="paramRuleConditionExp">
    <collection element-type="ParamRuleConditionExp"/>
    <extension key="inverse" value="paramRuleCondition"
    vendor-name="kodo"/>
    </field>
    <extension key="subclass-indicator-value" value="3"
    vendor-name="kodo"/>
    <extension key="table" value="RULE_CONDITION"
    vendor-name="kodo"/>
    <extension key="lock-column" value="none"vendor-name="kodo"/>
    </class>
    <class
    objectid-class="com.international.core.pk.ParamRuleConditionExpPK"
    identity-type="application" name="ParamRuleConditionExp">
    <field name="id" primary-key="true">
    <extension key="data-column" value="RULE_COND_ID"
    vendor-name="kodo"/>
    </field>
    <field name="paramRuleCondition">
    <extension key="id-data-column" value="RULE_COND_ID"
    vendor-name="kodo"/>
    </field>
    <field name="paramFeatureId" primary-key="true">
    <extension key="data-column" value="PARAM_FETR_ID"
    vendor-name="kodo"/>
    </field>
    <field name="parametricFeature">
    <extension key="paramFeatureId-data-column"
    value="PARAM_FETR_ID" vendor-name="kodo"/>
    </field>
    <field name="expressionValues">
    <collection element-type="ParametricExpValue"/>
    <extension key="inverse" value="paramRuleCondExp"
    vendor-name="kodo"/>
    </field>
    <extension key="class-column" value="none"vendor-name="kodo"/>
    <extension key="table" value="PARAM_RULE_CONDITION_EXP"
    vendor-name="kodo"/>
    <extension key="lock-column" value="none"vendor-name="kodo"/>
    </class>
    <class
    objectid-class="com.international.core.pk.ParametricFeaturePK"
    identity-type="application" name="ParametricFeature">
    <field name="paramFeatureId" primary-key="true">
    <extension key="data-column" value="PARAM_FETR_ID"
    vendor-name="kodo"/>
    </field>
    <field name="parametricFeatureCode">
    <extension key="data-column" value="PARAM_FETR_CD"
    vendor-name="kodo"/>
    </field>
    <extension key="class-column" value="none"vendor-name="kodo"/>
    <extension key="table" value="PARAMETRIC_FEATURE"
    vendor-name="kodo"/>
    <extension key="lock-column" value="none"vendor-name="kodo"/>
    </class>
    <class
    objectid-class="com.international.core.pk.ParametricExpValuePK"
    identity-type="application" name="ParametricExpValue">
    <field name="expValue" primary-key="true">
    <extension key="data-column" value="EXP_VAL"
    vendor-name="kodo"/>
    </field>
    <field name="id" primary-key="true">
    <extension key="data-column" value="RULE_COND_ID"
    vendor-name="kodo"/>
    </field>
    <field name="paramFeatureId" primary-key="true">
    <extension key="data-column" value="PARAM_FETR_ID"
    vendor-name="kodo"/>
    </field>
    <field name="paramRuleCondExp">
    <extension key="id-data-column" value="RULE_COND_ID"
    vendor-name="kodo"/>
    <extension key="paramFeatureId-data-column"
    value="PARAM_FETR_ID" vendor-name="kodo"/>
    </field>
    <extension key="class-column" value="none"vendor-name="kodo"/>
    <extension key="table" value="PARAMETRIC_EXP_VALUE"
    vendor-name="kodo"/>
    <extension key="lock-column" value="none"vendor-name="kodo"/>
    </class>
    </jdo>
    </package>
    THe error is something like
    [9/25/03 10:42:12:797 GMT+05:30] 44501d6f ExceptionUtil E CNTR0020E:
    Non-application exception occurred while processing method
    "createParamRuleCondition" on bean
    "BeanId(CdmsDeploy#cdms-ejb.jar#Validation, null)". Exception data:
    com.solarmetric.kodo.runtime.FatalDataStoreException:
    com.solarmetric.kodo.impl.jdbc.sql.SQLExceptionWrapper:
    [SQL=INSERT INTO PARAMETRIC_EXP_VALUE(EXP_VAL, PARAM_FETR_ID,
    RULE_COND_ID) VALUES ('100', null, null)]
    [PRE=INSERT INTO PARAMETRIC_EXP_VALUE(EXP_VAL, PARAM_FETR_ID,
    RULE_COND_ID) VALUES (?, ?, ?)]
    ORA-01400: cannot insert NULL into
    ("PARESH"."PARAMETRIC_EXP_VALUE"."RULE_COND_ID")
    [code=1400;state=23000]
    Steve Kim
    [email protected]
    SolarMetric Inc.
    http://www.solarmetric.com
    Marc Prud'hommeaux [email protected]
    SolarMetric Inc. http://www.solarmetric.com

  • Best way to combine Java Persistence API (JPA)  with Visual Web Pack (VWP)?

    I like the JPA/Hibernate development approach to create the database elements from JAVA classes.
    This way one gets rid of the need to keep JAVA code and the database in sync.
    However I have not yet found a good way on how to use JPA from the netbeans VWP.
    Note that I have found the tutorial on how to use the IDE with hibernate and it works without problems.
    However I think this tutorial does not really implement a good Model/View/Controller approach as it is done in the enterprise pack.
    Here you have a controller session bean that deals with all the persistence logic and that exposes properties through a DataModel to the application.
    There is no need to encapsulate logic in inherited classes of the ObjectListDataProvider.
    Maybe an example makes it more clear:
    If we stay with the hibernate tutorial that we have "Animals" and "Pavillion" entities.
    How would one efficiently design a "Table" component that shows a list of all Animals and their Pavillions.
    With the VWP approach it is quite clear: you create a RowSet with the inner/left join between Animals and Pavillions.
    But how would you do it with JPA?

    You said:
    "If we stay with the hibernate tutorial that we have "Animals" and "Pavillion" entities.
    How would one efficiently design a "Table" component that shows a list of all Animals and their Pavillions.
    With the VWP approach it is quite clear: you create a RowSet with the inner/left join between Animals and Pavillions.
    But how would you do it with JPA?"
    I have the exact same question. Have you found the answer on how to "join" entities and display them on visual web table component?

  • EclipseLink persistence provider issue with weblogic 10.3

    Hi All,
    I have been trying to deploy and run an EAR in weblogic but when I run the application I get the following warning: WARNING: Found unrecognized persistence provider "org.eclipse.persistence.jpa.PersistenceProvider" in place of OpenJPA provider. This provider's properties will not be used.
    The following is my persistence.xml:
    <persistence xmlns="http://java.sun.com/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/persistence persistence_1_0.xsd" version="1.0">
    <persistence-unit name="default" transaction-type="JTA">
    <provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
    <jta-data-source>DataSourceName</jta-data-source>
    <class>oracle.communications.platform.entity.impl.CharacteristicSpecificationDAO</class>
    <properties>
    <property name="eclipselink.logging.level" value="FINEST" />
    <property name="eclipselink.target-database" value="org.eclipse.persistence.platform.database.oracle.OraclePlatform" />
    <property name="eclipselink.target-server" value="WebLogic_10" />
    <property name="eclipselink.session-event-listener" value="oracle.communications.platform.persistence.impl.PomsSessionEventListener" />
    <property name="eclipselink.session.customizer" value="oracle.communications.platform.util.EclipseLinkSessionCustomizer" />
    <property name="poms.cache.coordination.implementation" value="jms" />
    <property name="poms.cache.coordination.ipaddress" value="10.178.139.64" />
    <property name="poms.cache.coordination.port" value="7101" />
    <property name="poms.cache.coordination.multicast.group.address" value="226.10.12.64" />
    <property name="poms.cache.coordination.multicast.port" value="3121" />
    <property name="poms.cache.coordination.topic.connection.factory.name" value="EclipseLinkTopicConnectionFactory" />
    <property name="poms.cache.coordination.topic.name" value="EclipseLinkTopic" />
    <property name="poms.cache.coordination.username" value="weblogic" />
    <property name="poms.cache.coordination.password" value="weblogic" />
    <property name="poms.cache.coordination.password.encrypted" value="false" />
    </properties>
    </persistence-unit>
    </persistence>
    I have written a session customizer that reads properties from the persistence.xml and initializes stuff. But because of the warning i mentioned earlier... I am getting null for all property entries.
    I moved the eclipselink jar entry up ahead of openjpa jar entry in weblogic.server.modules_10.3.1.0.xml and refcount.xml in /modules/features directory. I am still getting the same problem.
    I read in many posts for workarounds for this issue but didnt find anything which worked for me. I would be grateful if someone could provide me a hint as to how to make it work.
    Thanks in advance,
    Prashanth.

    Prashanth,
    Hi, there should be no issue running EclipseLink on WebLogic while you see this warning. If you are getting null properties it may be the result of another issue, could you post specific exceptions and the part of your client code that is having a problem.
    1) The warning below normally appears only when running your persistence unit with an "application managed" JTA datasource as opposed to a "globally defined server scoped datasource". Even then it can be ignored as there are still parts of WebLogic that depend on OpenJPA. Even though the warning states that properties are ignored - they are not and you should see your persistence unit loaded properly.
    I encountered this issue when running an "application managed" JTA - here is an extract of the log showing the warning and the full functioning of the pu later - the persistence unit and example code can be found on the weblogic tutorial examples link below
    "[EL Finer]: 2008.10.29 13:03:55.565--ClientSession(30346337)--Thread(Thread[[ACTIVE] ExecuteThread: '20' for queue: 'weblogic.kernel.Default (self-tuning)',5,Pooled Threads])--client released
    WARNING: Found unrecognized persistence provider "org.eclipse.persistence.jpa.PersistenceProvider" in place of OpenJPA provider. This provider's properties will not be used.
    [EL Info]: 2008.10.29 13:03:56.079--ServerSession(14772987)--EclipseLink, version: Eclipse Persistence Services - 1.1.0 (Build 20081023)
    [EL Info]: 2008.10.29 13:03:56.391--ServerSession(14772987)--file:/C:/view_w34r1a/examples/org.eclipse.persistence.example.jpa.server.weblogic.enterpriseEJB/build/classes/-exampleLocal login successful
    15 Entities in storage: 15
    [EL ExampleLocal EM]: enterprise: Object: [email protected]( id: 6 state: null parent: HashSet@15794734 references: HashSet@15794734)
    [EL ExampleLocal EM]: enterprise: Object: [email protected]( id: 26 state: null parent: HashSet@8800655 references: HashSet@8800655)
    I raised the following minor issue with our WebLogic Server team in Oct for reference - however this warning did not affect proper functioning of EclipseLink JPA.
    https://bug.oraclecorp.com/pls/bug/webbug_edit.edit_info_top?rptno=7520161
    You may reference the following tutorial on running EclipseLink JPA on WebLogic 10.3, it details all the steps necessary to get a JTA container managed persistence unit running via a stateless session bean and a servlet client. It also details and links to application managed datasource configuration details.
    http://wiki.eclipse.org/EclipseLink/Examples/JPA/WebLogic_Web_Tutorial
    2) eclipselink.jar location in WebLogic?
    The eclipselink.jar library should stay in the modules or patch_* directory depending on whether you are running a standalone WebLogic server or as part of a Fusion Middleware JDeveloper environment.
    See the following link that details deployment options for WebLogic and EclipseLink
    http://wiki.eclipse.org/EclipseLink/Examples/JPA/WebLogic_Web_Tutorial#EclipseLink_JAR_location
    Note: I have not modified the load order of EclipseLink, OpenJPA or Kodo, I am running all including this version of OpenJPA in my modules directory. [org.apache.openjpa_1.0.0.0_1-1-1-SNAPSHOT.jar]
    3) I noticed that you are defining the target-database property in your persistence unti but you are running as JTA not RESOURCE_LOCAL. This property can be removed if your JTA datasource is defined as a Transactional server scoped datasource via the WebLogic console.
    thank you
    /michael
    http://www.eclipselink.org

  • Org.eclipse.persistence.exceptions.ConversionException with INTERVALSD

    I have this issue with eclipselink 1.2.0.v20091016-r5565 and Oracle 11gR2
    column is INTERVAL DAY(5) TO SECOND(1) in database
    in EJB has been generated as Integer
    any workaround ???
    thank u
    patrick
    [EL Warning]: Exception [EclipseLink-3002] (Eclipse Persistence Services - 1.2.0.v20091016-r5565): org.eclipse.persistence.exceptions.ConversionException
    Exception Description: The object [0 0:0:2.400000000], of class [class oracle.sql.INTERVALDS], from mapping [org.eclipse.persistence.mappings.DirectToFieldMapping[flushElapsed-->sys.WRM$_SNAPSHOT.FLUSH_ELAPSED]] with descriptor [RelationalDescriptor(org.eclipse.persistence.extension.dynamic.WrmSnapshot --> [DatabaseTable(sys.WRM$_SNAPSHOT)])], could not be converted to [class java.lang.Integer].
    Exception in thread "main" Local Exception Stack:
    Exception [EclipseLink-3002] (Eclipse Persistence Services - 1.2.0.v20091016-r5565): org.eclipse.persistence.exceptions.ConversionException
    Exception Description: The object [0 0:0:2.400000000], of class [class oracle.sql.INTERVALDS], from mapping [org.eclipse.persistence.mappings.DirectToFieldMapping[flushElapsed-->sys.WRM$_SNAPSHOT.FLUSH_ELAPSED]] with descriptor [RelationalDescriptor(org.eclipse.persistence.extension.dynamic.WrmSnapshot --> [DatabaseTable(sys.WRM$_SNAPSHOT)])], could not be converted to [class java.lang.Integer].
    at org.eclipse.persistence.exceptions.ConversionException.couldNotBeConverted(ConversionException.java:71)
    at org.eclipse.persistence.internal.helper.ConversionManager.convertObjectToInteger(ConversionManager.java:539
    package org.eclipse.persistence.extension.dynamic;
    import java.io.Serializable;
    import java.sql.Timestamp;
    import javax.persistence.Column;
    import javax.persistence.Entity;
    import javax.persistence.Id;
    import javax.persistence.IdClass;
    import javax.persistence.NamedQueries;
    import javax.persistence.NamedQuery;
    import javax.persistence.Table;
    @Entity
    @NamedQueries({
    @NamedQuery(name = "WrmSnapshot.findAll", query = "select o from WrmSnapshot o")
    @Table(name = "WRM$_SNAPSHOT")
    @IdClass(WrmSnapshotPK.class)
    public class WrmSnapshot implements Serializable {
    @Column(name="BEGIN_INTERVAL_TIME", nullable = false)
    private Timestamp beginIntervalTime;
    @Column(name="BL_MOVED")
    private Long blMoved;
    @Id
    @Column(nullable = false)
    private Long dbid;
    @Column(name="END_INTERVAL_TIME", nullable = false)
    private Timestamp endIntervalTime;
    @Column(name="ERROR_COUNT")
    private Long errorCount;
    @Column(name="FLUSH_ELAPSED")
    private Integer flushElapsed;
    @Id
    @Column(name="INSTANCE_NUMBER", nullable = false)
    private Long instanceNumber;
    @Column(name="SNAP_FLAG")
    private Long snapFlag;
    @Id
    @Column(name="SNAP_ID", nullable = false)
    private Long snapId;
    @Column(name="SNAP_LEVEL")

    It probably depends on which tool are you using to generate EJB's from tables, but i don't think it's possible to make it use String for INTERVAL fields.
    I don't have much experience with working with INTERVAL fields but my guess is that they are converted to Lob's instead of byte array (Lob actually make sense as a representation of byte array). My other guess is that if you choose String for your field then when read from DB it is first converted to Lob then to String, but proper mapping for INTERVAL field is Lob. Number field can be converted to String but its not a "proper" way to handle Number fields.

  • Reachability with a strict reading of the JLS

    Hi,
    I have a small question, please tell me what you think.
    Given the following codepublic class ReachableTest {
         public static void main (String[] args) {
              ExpensiveObject o = new ExpensiveObject ();
              byte[][] arr = new byte[100][];
              for (int i = 0; i < 100; i++) {
                   arr[i] = new byte[1000000];
    class ExpensiveObject {
         private final byte[] expensive = new byte[100000000];
         @Override
         public String toString () {
              return expensive.toString ();
    }at which point is the ExpensiveObject eligible for garbage collection? Running the example with java -Xmx100m ReachableTest gives an OutOfMemoryError as the Sun JVM won't collect the variable o before the end of the method. My question is, given the following note in the JLS, could a conformant JVM collect the ExpensiveObject before the loop begins?
    "A reachable object is any object that can be accessed in any potential continuing computation from any live thread. Optimizing transformations of a program can be designed that reduce the number of objects that are reachable to be less than those which would naively be considered reachable. For example, a compiler or code generator may choose to set a variable or parameter that will no longer be used to null to cause the storage for such an object to be potentially reclaimable sooner." http://java.sun.com/docs/books/jls/third_edition/html/execution.html#44762

    My question
    is, given the following note in the JLS, could a
    conformant JVM collect the ExpensiveObject before the
    loop begins?Yes. Indeed, with the code as given, a comformant JVM could conceivably not bother to instantiate ExpensiveObject in the first place, since its constructor has no side effects, and the reference is never used.
    The new Java Memory Model, which is part of Java 1.5, somewhat changes the rules about reachability, particularly as regards references held in static fields, but it wouldn't affect your example.
    Sylvia.

  • Persistence and XA with MDBs

    Hi,
              We currently run WLS 6.1, SP3. We'd like to use Message Driven Beans over MQSeries. Does anyone know what the minimum version of WLS/SP is needed to make this work? Also, is there any clear documentation on the BEA site. I haven't seen anything.
              Thanks,
              Frank
              

    Hi Frank,
              In 6.1 you can use the messaging bridge (with patches) to forward
              the MQ messages transactionally to a WL destination, and then have
              the MDB transactionally read from the WL destination. Otherwise,
              you can use 7.0 to have MQ drive the MDB directly.
              I highly recommend you start by reading this white-paper
              on dev2dev.bea.com:
              "Whitepaper: Using Foreign JMS Providers with WebLogic Server"
              Note that this white-paper does not take into account
              some 8.1 ease-of-use features that simplify
              integration - see the 8.1 release notes for the two following
              JMS features:
              Foreign Vendor Destination Wrappers
              and
              Resource-Reference Pools
              (I may have the names wrong, but don't have time to look
              them up.)
              Note also that the very latest version of MQ provides
              a remote capable XA JMS client. Previous versions only
              supported transactions if the MQ client ran on the same
              server as the MQ server.
              Tom, BEA
              Frank Guerino wrote:
              > Hi,
              >
              > We currently run WLS 6.1, SP3. We'd like to use Message Driven Beans over MQSeries. Does anyone know what the minimum version of WLS/SP is needed to make this work? Also, is there any clear documentation on the BEA site. I haven't seen anything.
              >
              > Thanks,
              >
              > Frank
              >
              

  • Persistence in EJB3 with Netbeans

    Hello!
    Anybody who have a small example project made in Netbeans that uses persistence?

    Not exactly the same thing, but NetBeans has a short tutorial for EJB 3.0 here :
    http://www.netbeans.org/kb/55/ejb30.html

  • Help with a design, using Java Persistence

    I'm having a design issue, and I hope that someone can help.
    I have a table called Item, and it essentially acts as a header table for a group of attributes for that item.
    TABLE Item
    .....id....................long
    .....itemName.........varchar
    .....StartDate........datetime
    .....StopDate........datetime
    If I can, I'd like to design a model that will allow for a dynamic number of attributes for any given ITEM.
    I initially thought that it would be convenient to design the Attributes table like such:
    TABLE Attribute
    .....id....................long
    .....itemID.............long (references Item.id)
    .....attributeName....varchar
    .....value...............?
    .....StartDate.........datetime
    .....StopDate.........datetime
    My problem is the VALUE column. Attributes can be any given type, so this won't work if I want to enforce a data type.
    I don't know where to go from here. I can create a table to include all attributes, but each attribute needs to have a date range.
    Additionally, the history of the attributes must be retained; so, if I succeeded any given Attribute I would need to duplicate the
    entire row (thus, all the other data that didn't change).
    One thought was to create an Attribute table for each of the most common types, but that seems like a really bad idea:
    TABLE AttributeLong
    TABLE AttributeDateTime
    TABLE AttributeVarchar
    etc, etc ...
    I should note that I'm using Java Persistence.

    I agree with you 100%. Here is something I'm trying to get a grip on: there are a finite number of attributes per group, but the number of attribute groups can grow (maybe 20 sets max - but I just don't know yet).
    I would need one table (Entity) for each set of attributes.
    So, for instance, let's say I have:
    Item1 is of kind KIND1 that has an attribute set of SET1
    (ie, tables ITEM and SET1)
    Item2 is of kind KIND2 that has an attribute set of SET2
    (ie, tables ITEM and SET2)
    I'd like to have my Item entity class set up like such:
    myItem.getAttributeSet
    instead of:
    myItem.getAttributeSet1
    myItem.getAttributeSet2
    Since at given time I can extend my application (and add new entity classes to support a new table for SET3), I wanted to avoid changing Item. I can have getAttributeSet return an interface and then cast it, but that still requires changing Item to account for the new entities. Thus, I can't just drop in new "packages."
    I want a flexible and extensible system., but maybe I'm over thinking/engineering this.

  • Override JNDI names in persistence.xml and @resource annotation

    I have a Java EE 7 application that I am developing for use with both GlassFish and WildFly, but I have discovered that both application servers use a slightly different format for specifying JNDI names.
    In GlassFish the persistence.xml file references the data source jdbc/myDataSouce, but in WildFly the data source needs to be java:/jdbc/myDataSource.The same is also true for classes that are annotated with @Resource. In GlassFish the annotation for a class using JavaMail would be @Resource(name = "mail/myMailSession"), but to deploy onto WildFly this would need to be @Resource(name = "java:mail/myMailSession").
    The only solution I've got at present is using Maven to create two different releases of the EAR file, with one EAR file containing a persistence.xml file with the data source jdbc/myDataSouce for use with GlassFish, and the second EAR file containing a persistence.xml file with the data source java:/jdbc/myDataSource for use with WildFly. Unfortunately, I haven't found a solution for the @Resource annotation.
    I've taken a look at the documentation for glassfish-application.xml and glassfish-ejb-jar.xml and have tried using resource-ref to override the JNDI names but the application fails to deploy due to an error in the name.
    My question is does GlassFish provide any capability to override the JNDI names specified in the persistence.xml file and classes with the @resource annotation?
    Many Thanks
    Paul

    Have you been able to solve this? I'm attempting to understand what Web Server 7 can do with regard to Java Persistence and what elements of it require Glassfish.
    I've also spent great amounts of time in WS6.1 trying to figure out why a JNDI resource couldn't be found. The rules of thumb I've learned are:
    - Try dropping the *'java:/comp/env/* prefix; just use jdbc/pact part
    - Make sure all referrences (in web.xml and sun-web.xml) are identical with regard to that name.
    I'm hoping you're not still dealing with this (it's been two months!) but if anybody else stumbles on this, maybe it'll help them.
    Dave

  • SQL exception during creation of a physical standby database with EM

    Version: EM Oracle 10.2.5 (agents running, repository running, primary db running, all targets visible and reachable with EM)
    I try to create a physical standby database with the enterprise manager and each time the process is aborted with a SQL exception during the preparation of the job by the EM. I have added a part of the OMs log containing the error at the end of the excerpt.
    =============
    2010-04-29 16:00:39,856 [EMUI_16_00_39_/console/targets] WARN pref.SubtabPref getFolders.710 - Unknown folder id: VirtualServers retrieved from repository
    2010-04-29 16:01:04,765 [EMUI_16_01_04_/console/database/dataguard/create] ERROR em.dataguard validate.1329 - CreateBean: ClassNotFoundException: null
    2010-04-29 16:02:05,476 [EMUI_16_02_05_/console/database/dataguard/create] ERROR jobs.dbclone checkSetFileError.79 - DatabaseFileAttributes.checkSetFileError(): Null database file!
    2010-04-29 16:02:05,476 [EMUI_16_02_05_/console/database/dataguard/create] ERROR jobs.dbclone setControlfiles.160 - DatabaseFileAttributes.setDatafiles(): Invalid control file!
    2010-04-29 16:02:05,492 [EMUI_16_02_05_/console/database/dataguard/create] ERROR jobs.dbclone getControlFileNames.616 - DatabaseFileAttributes.getDatafileNames(): null datafile names!
    2010-04-29 16:02:32,823 [Thread-28] ERROR em.jobs remoteOp.2389 - DBVerify.remoteOp(): Error: max_stamp# 6071384
    2010-04-29 16:02:32,823 [Thread-28] ERROR jobs.dbclone submitJobPreparation.3297 - DBCloneObject.submitJobPreparation(): getMaxLogSequenceNum: Während der Vorbereitung des Jobs ist eine SQL Exception aufgetreten. Um das Problem zu diagnostizieren, legen Sie das Agent Perl-Skript-Tracing auf DEBUG fest und wiederholen den Vorgang
    2010-04-29 16:02:32,823 [Thread-28] ERROR jobs.dbclone submitJobPreparation.3501 - DBCloneObject.submitJobPreparation(): Exception: java.lang.Exception: Während der Vorbereitung des Jobs ist eine SQL Exception aufgetreten. Um das Problem zu diagnostizieren, legen Sie das Agent Perl-Skript-Tracing auf DEBUG fest und wiederholen den Vorgang
    2010-04-29 16:02:32,823 [Thread-28] ERROR jobs.dbclone submitDBCloneJob.3716 - DBCloneObject.submitDBCloneJob(): Exception: Während der Vorbereitung des Jobs ist eine SQL Exception aufgetreten. Um das Problem zu diagnostizieren, legen Sie das Agent Perl-Skript-Tracing auf DEBUG fest und wiederholen den Vorgang
    2010-04-29 16:02:37,496 [EMUI_16_02_37_/console/database/dataguard/create] ERROR em.dataguard onEvent.1243 - CreateConfigController: Exception: oracle.sysman.db.dg.util.VxxStandbyException: Während der Vorbereitung des Jobs ist eine SQL Exception aufgetreten. Um das Problem zu diagnostizieren, legen Sie das Agent Perl-Skript-Tracing auf DEBUG fest und wiederholen den Vorgang
    =========
    I have set the agent perl script tracing to DEBUG, but can't find any reason, why the job preparation failed.
    Has anyone an idea why the job cannot be prepared? Thanks in advance for investigation :-)

    Can you please tell me how can i see data gaurd on EM..
    I have oracle 11gR1..i have implemmented primary as well standby database..
    I have already started EM but i have no idea where to find datagaurd option..or how to create standdby db using EM..
    You got error that means u did it using EM..how can i do it on EM

  • How to send an Email with content at the end of a Quiz?

    Hello,
    i have three Questions about the navigation function "sending an Email" at the end of an Test or Quiz, and i haven´t found any answers in the forum yet.
    An Information at the beginning:
    I want to use the Test without any other System, for example Moodle. It will be directly reachable with a link on a homepage.
    1) Is it possible, to send an Email with answers of the User as the content in the email, and if it´s possible, how?
    2) If it´s not possible, could i precast a Text in the email? Until now, there is only an empty Outlook-Window with the Emailadress.
    3) Is it possible, to send an Email without Outlook, so a User can use it only web-based, for example with gmx, webmail etc...
    Thank you for helping me
    Zholmar
    (German)
    Hallo,
    ich habe drei Fragen zum Versand im Rahmen der Navigationsfunktion von "Email versenden", dies soll am Ende von Test bzw. Quizanwendungen geschehen und habe im Forum leider keine entsprechende Antwort bisher gefunden.
    Zur Information:
    Der Test soll nicht in ein anderes System (z.B. Moodle) eingebettet werden, sondern lediglich per Link auf einer Homepage erreichbar sein.
    1) Ich würde gerne am Ende meines Tests eine Email versenden lassen, welche die Antworten des vorangegangenen Tests enthält, ist das möglich und wenn ja wie?
    2) Falls das nicht möglich ist, besteht die Möglichkeit, einen vorgefertigten Text + Betreff in der Email zu generieren? Derzeit öffnet sich lediglich ein Outlook Fenster bei erreichen der Folie, in welcher lediglich die angegebene Emailadresse eingetragen ist. In dieser Email soll wenn möglichst bereits ein Text integriert sein, so dass der Teilnehmer lediglich noch Angaben ergänzen muss.
    3) Ist der Email Versand auch ohne Outlook möglich? Kann die Funktion also auch rein Webbasiert erfolgen?
    Vielen Dank für die Hilfe
    Zholmar

    Sooo, which method are you wanting to use?
    Earlier I outlined the steps for the close project at end.
    If you are wanting to use the JavaScript solution, you insert a button. Then in the action, you tell the button to execute JavaScript. Then you click the Script Window button and enter the window.close(); code.
    Cheers... Rick

  • Unable to open documents with policies

    We are using a test version of the policy server to evaluate the features of the product.
    We had some trouble to install the server and to use it with Adobe Professional but now we can protect pdf files with policies. Most of the problems was solved with the help of articles in these forum :-)
    Unfortunately we are not able to open the documents with the Adobe Reader :-( Only the computer on which the documents were protected is able to show the files. On all other computers we became the error message
    b "Your computer has to be connected to network. Your right to open these document offline is expired."
    In German: b "Dieser Computer muss mit dem Netzwerk verbunden sein, um dieses Dokument zu öffnen. Ihre Berechtigung, dieses Dokument offline zu öffnen, ist abgelaufen. Wenn dieser Computer nicht mit dem Netzwerk verbunden ist, stellen sie eine Verbindung her, und versuchen sie erneut, das Dokument zu öffnen."
    The policy server is reachable with browser and ssl works.
    Reader versions: 7.0.0, 7.0.5, 7.0.8
    Regards

    It's been my experience that when you get the "Not Connected to Network" message, it simply means that the client PC doesn't have the certificate of authentication installed.
    I suggest that you check to see if the certificate is installed on the PC that's connecting. (In IE, you would click on Tools-Internet Options-Content-Certificates.) Then check a computer that's not connected. If there is no certificate installed, it won't connect. To install a certificate, you must click "View Certificate" immediately after a hitting the page and getting the security dialog warning, then click "Install Certificate."
    Hope this helps.

  • Multiple persistence.xml files

    I've got a situation where I have one persistence.xml file with many persistence-unit's. My problem is that during deployment not all of the persistence-units are useable, so I get errors. My question is can I use multiple persistence.xml files in an application if each persistence.xml file defined only one persistence-unit?
    Mark

    While JPA supports multiple persistence units in a single persistence.xml most of the tooling options (Eclipse, JDeveloper) focus on supporting a single persistence unit. Using multiple persistence.xml files on different classpath roots should also work. I recall seeing a bug related to this in the EclipseLink queue. Is this the JPA implementation you are using?
    Doug

Maybe you are looking for