In order to get the PSML working in Oracle, from the 1.5 binary
distribution of Jetspeed, in addition to following the instructions
here regarding importing,
http://portals.apache.org/jetspeed-1/psml_db.html, I also had to make
some changes to class files and sql files.

You need both the src and binary distributions.  There's a diff of the
relevant files below.

Modify the java files:
Add _SEQ onto the value in setPrimaryKeyMethodInfo in each of the
org/apache/jetspeed/om/dbpsml/map/Jetspeed* files.

Modify the psml-db-oracle.sql file (from the src distribution):
Change each of the id columns to PSML_ID, in both places.
Change LOGIN_NAME to USER_NAME.
Remove each of the unique constraints on _NAME columns (login, role,
group).  (I'm not entirely certain about this, but I think if you need
to support multiple languages, you don't want that constraint.)

I tried following the directions to generate the sql files outlined in
http://portals.apache.org/jetspeed-1/psml_db.html to see if the
torque-schema fixed these issues, but didn't see any sql files
generated.

After making these changes, and putting the classes in the classpath, I
was able to able to import profiles and login successfully.

Have a nice day.
Dan

diff-------------------
diff change/JetspeedGroupProfileMapBuilder.java
orig/JetspeedGroupProfileMapBuilder.java
67c67
<         tMap.setPrimaryKeyMethodInfo("JETSPEED_GROUP_PROFILE_SEQ");
---
>         tMap.setPrimaryKeyMethodInfo("JETSPEED_GROUP_PROFILE");
diff change/JetspeedRoleProfileMapBuilder.java
orig/JetspeedRoleProfileMapBuilder.java
67c67
<         tMap.setPrimaryKeyMethodInfo("JETSPEED_ROLE_PROFILE_SEQ");
---
>         tMap.setPrimaryKeyMethodInfo("JETSPEED_ROLE_PROFILE");
diff change/JetspeedUserProfileMapBuilder.java
orig/JetspeedUserProfileMapBuilder.java
67c67
<         tMap.setPrimaryKeyMethodInfo("JETSPEED_USER_PROFILE_SEQ");
---
>         tMap.setPrimaryKeyMethodInfo("JETSPEED_USER_PROFILE");
Only in orig/: orig
diff change/psml-db-oracle.sql orig/psml-db-oracle.sql
25,26c25,26
<          PSML_ID INT NOT NULL,
<          USER_NAME VARCHAR2 (32) NOT NULL,
---
>          USER_ID INT NOT NULL,
>          LOGIN_NAME VARCHAR2 (32) NOT NULL,
31c31,32
<          PROFILE LONG RAW
---
>          PROFILE LONG RAW,
>          UNIQUE (LOGIN_NAME)
36c37
< PRIMARY KEY (PSML_ID);
---
> PRIMARY KEY (USER_ID);
48c49
<          PSML_ID INT NOT NULL,
---
>          GROUP_ID INT NOT NULL,
54c55,56
<          PROFILE LONG RAW
---
>          PROFILE LONG RAW,
>          UNIQUE (GROUP_NAME)
59c61
< PRIMARY KEY (PSML_ID);
---
> PRIMARY KEY (GROUP_ID);
71c73
<          PSML_ID INT NOT NULL,
---
>          ROLE_ID INT NOT NULL,
77c79,80
<          PROFILE LONG RAW
---
>          PROFILE LONG RAW,
>          UNIQUE (ROLE_NAME)
82c85
< PRIMARY KEY (PSML_ID);
---
> PRIMARY KEY (ROLE_ID);



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

Reply via email to