Hi everybody!
I'm pretty new to applicationservers and right now I'm exploring the o/r mapping
fascilities in orion. I have read the examples
(atm, complex-or on orion support, etc)
and the mail archive, but there is still lot of things that I don't understand. I
would appreciate if
somebody could help me with following questions:
1. When orion is autocreating a table the following message appear:
Auto-creating table: create table JOrder (orderId varchar2(255) not null primary
key, name varchar2(255) null)
But in the table, there is no primary key.
(SELECT COLUMN_NAME FROM USER_CONSTRAINTS, USER_CONS_COLUMNS
WHERE USER_CONSTRAINTS.CONSTRAINT_NAME=USER_CONS_COLUMNS.CONSTRAINT_NAME
AND CONSTRAINT_TYPE='P'
AND USER_CONSTRAINTS.TABLE_NAME='JORDER';
no rows selected )
This is really strange beacause I'm certain of that it sometimes creates primary keys.
However, is this correct? If it is, searching a table, would mean a full table-scan or
a sequential search every time one search.
(I believe that there is no indexes either).
2. After succesfully implemented aggregation I turned to assocation and I'm still
trying. If I don't get the error message
"missing a no-arg constructor" I get "Internal error, unset persitence type for
member... : 0". I read in the mail archive that
that the last message is related to ejb2.0, i.e. I'am using 2.0 functionality. Does
somebody have an example
on assocation, i.e. a relation, one-many, between two entity-beans with ejb1.1,
especielly the orion-ejb-jar.xml file.
3. I'm also trying to grasp the ATM example (EJB 2.0). In the example, there is an one
to many relation between AccountOwner and
Account. In the orion-ejb-jar.xml, the relation is mapped to a new table. How come?
Why not by a foreign key in the Acoount table?
Does the <entity ref> mean that you store the reference to the entity-object?
4. Generally I think that the mapping mechanismen is hard to understand, especially
the orion-ejb-jar.xml. So I would be grateful
for any input.
I'm using Orion 1.3.8 and Oracle
Best regards
/Theis.