Yes. I did my connection setting as below:
<dbunit.dataTypeFactoryName>org.dbunit.ext.oracle.OracleDataTypeFactory</dbunit.dataTypeFactoryName> <dbunit.schema>NOC</dbunit.schema> <!-- Make sure to capitalize the schema name --> <dbunit.operation.type>CLEAN_INSERT</dbunit.operation.type> <hibernate.dialect>org.hibernate.dialect.Oracle10gDialect</hibernate.dialect> <hibernate.show_sql>true</hibernate.show_sql> <jdbc.groupId>com.oracle</jdbc.groupId> <jdbc.artifactId>ojdbc14</jdbc.artifactId> <jdbc.version>10.2.0.2.0</jdbc.version> <jdbc.driverClassName>oracle.jdbc.OracleDriver</jdbc.driverClassName> <jdbc.url><![CDATA[jdbc:oracle:thin:@devdb:1521:net01d]]></jdbc.url> <jdbc.username>i123</jdbc.username> <jdbc.password>i123</jdbc.password> On Mon, May 12, 2008 at 10:46 AM, Dustin Pearce <[EMAIL PROTECTED]> wrote: > Have you set this up in the pom.xml? > > <dbunit.schema>YOUR_SCHEMA_NAME</dbunit.schema> > <!-- Make sure to capitalize the schema name --> > > -D > > > On May 12, 2008, at 10:07 AM, MHL wrote: > > > > Thanks for the reply. > > > > > > here is the stacktrace: > > + Error stacktraces are turned on. > > [INFO] Scanning for projects... > > [INFO] > > ------------------------------------------------------------------------ > > [INFO] Building Tantalus BidGen Application > > [INFO] task-segment: [test] > > [INFO] > > ------------------------------------------------------------------------ > > [INFO] [aspectj:compile {execution: default}] > > [INFO] [native2ascii:native2ascii {execution: native2ascii-utf8}] > > [INFO] [native2ascii:native2ascii {execution: native2ascii-8859_1}] > > [INFO] [resources:resources] > > [INFO] Using default encoding to copy filtered resources. > > [INFO] [compiler:compile] > > [INFO] Nothing to compile - all classes are up to date > > [INFO] [resources:testResources] > > [INFO] Using default encoding to copy filtered resources. > > [INFO] Preparing hibernate3:hbm2ddl > > [WARNING] Removing: hbm2ddl from forked lifecycle, to prevent recursive > > invocation. > > [INFO] [aspectj:compile {execution: default}] > > [INFO] [native2ascii:native2ascii {execution: native2ascii-utf8}] > > [INFO] [native2ascii:native2ascii {execution: native2ascii-8859_1}] > > [INFO] [resources:resources] > > [INFO] Using default encoding to copy filtered resources. > > [WARNING] POM for 'org.hibernate:jtidy:pom:r8-20060801:runtime' is > > invalid. > > It will be ignored for artifact resolution. Reason: Parse error reading > > POM. > > Reason: TEXT must be immediately followed by END_TAG and not START_TAG > > (position: START_TAG seen ...<licenses>\n\t\t\t<license>... @12:13) for > > project org.hibernate:jtidy at > > c:\mavenrepo\org\hibernate\jtidy\r8-20060801\jtidy-r8-20060801.pom > > [WARNING] POM for 'org.hibernate:jtidy:pom:r8-20060801:runtime' is > > invalid. > > It will be ignored for artifact resolution. Reason: Parse error reading > > POM. > > Reason: TEXT must be immediately followed by END_TAG and not START_TAG > > (position: START_TAG seen ...<licenses>\n\t\t\t<license>... @12:13) for > > project org.hibernate:jtidy at > > c:\mavenrepo\org\hibernate\jtidy\r8-20060801\jtidy-r8-20060801.pom > > [INFO] [hibernate3:hbm2ddl {execution: default}] > > [INFO] Configuration XML file loaded: > > C:\appfuse\bidgen\src\main\resources\hibernate.cfg.xml > > [INFO] Configuration XML file loaded: > > C:\appfuse\bidgen\src\main\resources\hibernate.cfg.xml > > [INFO] Configuration Properties file loaded: > > C:\appfuse\bidgen\target\classes\jdbc.properties > > drop table app_user cascade constraints; > > drop table role cascade constraints; > > drop table user_role cascade constraints; > > drop sequence hibernate_sequence; > > create table app_user (id number(19,0) not null, username varchar2(50 > > char) > > not null unique, email varchar2(255 char) not null unique, password_hint > > varchar2(255 char), first_name varchar2(50 char) not null, last_name > > varchar2(50 char) not null, phone_number varchar2(255 char), website > > varchar2(255 char), account_expired number(1,0) not null, account_locked > > number(1,0) not null, credentials_expired number(1,0) not null, city > > varchar2(50 char) not null, province varchar2(100 char), postal_code > > varchar2(15 char) not null, address varchar2(150 char), country > > varchar2(100 > > char), account_enabled number(1,0), version number(10,0), password > > varchar2(255 char) not null, primary key (id)); > > create table role (id number(19,0) not null, name varchar2(20 char), > > description varchar2(64 char), primary key (id)); > > create table user_role (user_id number(19,0) not null, role_id > > number(19,0) > > not null, primary key (user_id, role_id)); > > alter table user_role add constraint FK143BF46A8B467AF1 foreign key > > (role_id) references role; > > alter table user_role add constraint FK143BF46A30713ED1 foreign key > > (user_id) references app_user; > > create sequence hibernate_sequence; > > [INFO] [compiler:testCompile] > > [INFO] Nothing to compile - all classes are up to date > > [INFO] [dbunit:operation {execution: test-compile}] > > [INFO] > > ------------------------------------------------------------------------ > > [ERROR] BUILD ERROR > > [INFO] > > ------------------------------------------------------------------------ > > [INFO] Error executing database operation: CLEAN_INSERT > > > > Embedded error: user_role > > [INFO] > > ------------------------------------------------------------------------ > > [INFO] Trace > > org.apache.maven.lifecycle.LifecycleExecutionException: Error executing > > database operation: CLEAN_INSERT > > at > > > > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:564) > > at > > > > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:480) > > at > > > > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:459) > > at > > > > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:311) > > at > > > > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:278) > > at > > > > org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:143) > > at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:333) > > at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:126) > > at org.apache.maven.cli.MavenCli.main(MavenCli.java:282) > > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > > at > > > > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) > > at > > > > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) > > at java.lang.reflect.Method.invoke(Method.java:597) > > at > > org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315) > > at org.codehaus.classworlds.Launcher.launch(Launcher.java:255) > > at > > org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430) > > at org.codehaus.classworlds.Launcher.main(Launcher.java:375) > > Caused by: org.apache.maven.plugin.MojoExecutionException: Error > > executing > > database operation: CLEAN_INSERT > > at > > org.codehaus.mojo.dbunit.OperationMojo.execute(OperationMojo.java:110) > > at > > > > org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:447) > > at > > > > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:539) > > ... 16 more > > Caused by: org.dbunit.dataset.NoSuchTableException: user_role > > at > > > > org.dbunit.database.DatabaseDataSet.getTableMetaData(DatabaseDataSet.java:192) > > at > > > > org.dbunit.operation.DeleteAllOperation.execute(DeleteAllOperation.java:98) > > at > > > > org.dbunit.operation.CompositeOperation.execute(CompositeOperation.java:67) > > at org.dbunit.ant.Operation.execute(Operation.java:183) > > at > > org.codehaus.mojo.dbunit.OperationMojo.execute(OperationMojo.java:101) > > ... 18 more > > [INFO] > > ------------------------------------------------------------------------ > > [INFO] Total time: 14 seconds > > [INFO] Finished at: Mon May 12 10:05:50 PDT 2008 > > [INFO] Final Memory: 14M/32M > > [INFO] > > ------------------------------------------------------------------------ > > > > thanks. > > > > > > dusty wrote: > > > > > > > > Can you run that again with mvn -e test -Poracle? > > > > > > You connected to oracle using the profile, correct? We need to see > > > the actual stacktrace for the Oracle error. > > > > > > -D > > > > > > On May 9, 2008, at 4:53 PM, MHL wrote: > > > > > > > > > > Hi all. > > > > > > > > When I switch the database from Mysql to Oracle. it gives me errors > > > > as > > > > below. > > > > > > > > I have been scatched my head for few hours and I still can't come up > > > > a > > > > solution. > > > > > > > > Can someone please help me out? > > > > > > > > > > > > thanks. > > > > > > > > the error messages as below: > > > > > > > > [INFO] Scanning for projects... > > > > [INFO] > > > > > > > > ------------------------------------------------------------------------ > > > > [INFO] Building Tantalus BidGen Application > > > > [INFO] task-segment: [test] > > > > [INFO] > > > > > > > > ------------------------------------------------------------------------ > > > > [INFO] [aspectj:compile {execution: default}] > > > > [INFO] [native2ascii:native2ascii {execution: native2ascii-utf8}] > > > > [INFO] [native2ascii:native2ascii {execution: native2ascii-8859_1}] > > > > [INFO] [resources:resources] > > > > [INFO] Using default encoding to copy filtered resources. > > > > [INFO] [compiler:compile] > > > > [INFO] Nothing to compile - all classes are up to date > > > > [INFO] [resources:testResources] > > > > [INFO] Using default encoding to copy filtered resources. > > > > [INFO] Preparing hibernate3:hbm2ddl > > > > [WARNING] Removing: hbm2ddl from forked lifecycle, to prevent > > > > recursive > > > > invocation. > > > > [INFO] [aspectj:compile {execution: default}] > > > > [INFO] [native2ascii:native2ascii {execution: native2ascii-utf8}] > > > > [INFO] [native2ascii:native2ascii {execution: native2ascii-8859_1}] > > > > [INFO] [resources:resources] > > > > [INFO] Using default encoding to copy filtered resources. > > > > [WARNING] POM for 'org.hibernate:jtidy:pom:r8-20060801:runtime' is > > > > invalid. > > > > It will be ignored for artifact resolution. Reason: Parse error > > > > reading POM. > > > > Reason: TEXT must be immediately followed by END_TAG and not > > > > START_TAG > > > > (position: START_TAG seen ...<licenses>\n\t\t\t<license>... @12:13) > > > > for > > > > project org.hibernate:jtidy at > > > > c:\mavenrepo\org\hibernate\jtidy\r8-20060801\jtidy-r8-20060801.pom > > > > [WARNING] POM for 'org.hibernate:jtidy:pom:r8-20060801:runtime' is > > > > invalid. > > > > It will be ignored for artifact resolution. Reason: Parse error > > > > reading POM. > > > > Reason: TEXT must be immediately followed by END_TAG and not > > > > START_TAG > > > > (position: START_TAG seen ...<licenses>\n\t\t\t<license>... @12:13) > > > > for > > > > project org.hibernate:jtidy at > > > > c:\mavenrepo\org\hibernate\jtidy\r8-20060801\jtidy-r8-20060801.pom > > > > [INFO] [hibernate3:hbm2ddl {execution: default}] > > > > [INFO] Configuration XML file loaded: > > > > C:\appfuse\bidgen\src\main\resources\hibernate.cfg.xml > > > > [INFO] Configuration XML file loaded: > > > > C:\appfuse\bidgen\src\main\resources\hibernate.cfg.xml > > > > [INFO] Configuration Properties file loaded: > > > > C:\appfuse\bidgen\target\classes\jdbc.properties > > > > drop table app_user cascade constraints; > > > > drop table role cascade constraints; > > > > drop table user_role cascade constraints; > > > > drop sequence hibernate_sequence; > > > > create table app_user (id number(19,0) not null, username > > > > varchar2(50 char) > > > > not null unique, email varchar2(255 char) not null unique, > > > > password_hint > > > > varchar2(255 char), first_name varchar2(50 char) not null, last_name > > > > varchar2(50 char) not null, phone_number varchar2(255 char), website > > > > varchar2(255 char), account_expired number(1,0) not null, > > > > account_locked > > > > number(1,0) not null, credentials_expired number(1,0) not null, city > > > > varchar2(50 char) not null, province varchar2(100 char), postal_code > > > > varchar2(15 char) not null, address varchar2(150 char), country > > > > varchar2(100 > > > > char), account_enabled number(1,0), version number(10,0), password > > > > varchar2(255 char) not null, primary key (id)); > > > > create table role (id number(19,0) not null, name varchar2(20 char), > > > > description varchar2(64 char), primary key (id)); > > > > create table user_role (user_id number(19,0) not null, role_id > > > > number(19,0) > > > > not null, primary key (user_id, role_id)); > > > > alter table user_role add constraint FK143BF46A8B467AF1 foreign key > > > > (role_id) references role; > > > > alter table user_role add constraint FK143BF46A30713ED1 foreign key > > > > (user_id) references app_user; > > > > create sequence hibernate_sequence; > > > > [INFO] [compiler:testCompile] > > > > [INFO] Nothing to compile - all classes are up to date > > > > [INFO] [dbunit:operation {execution: test-compile}] > > > > [INFO] > > > > > > > > ------------------------------------------------------------------------ > > > > [ERROR] BUILD ERROR > > > > [INFO] > > > > > > > > ------------------------------------------------------------------------ > > > > [INFO] Error executing database operation: CLEAN_INSERT > > > > > > > > Embedded error: user_role > > > > [INFO] > > > > > > > > ------------------------------------------------------------------------ > > > > [INFO] For more information, run Maven with the -e switch > > > > [INFO] > > > > > > > > ------------------------------------------------------------------------ > > > > [INFO] Total time: 9 seconds > > > > [INFO] Finished at: Fri May 09 16:47:27 PDT 2008 > > > > > > > > > > > > -- > > > > View this message in context: > > > > > > > > http://www.nabble.com/Appfuse-2.0.1-and-Oracle.-tp17158334s2369p17158334.html > > > > Sent from the AppFuse - User mailing list archive at Nabble.com. > > > > > > > > > > > > > > > > --------------------------------------------------------------------- > > > > 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] > > > > > > > > > > > > > > -- > > View this message in context: > > http://www.nabble.com/Appfuse-2.0.1-and-Oracle.-tp17158334s2369p17189876.html > > Sent from the AppFuse - User mailing list archive at Nabble.com. > > > > > > --------------------------------------------------------------------- > > 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] > > -- Ben Li