WebSphere Commerce Developer

Changing the development database type by using the setdbtype command

After you install WebSphere Commerce Developer, the development environment is configured to use the Apache Derby database. If needed, you can change the database type to DB2, Oracle, or back to Apache Derby, by running the setdbtype command. Ensure that the database that you are switching to exists in your network. Changing development database types does not carry over any schema customizations or custom data to the new database.

Important: If you are migrating WebSphere Commerce Developer from a previous version, ensure that you use the same database type in your new development environment. To change the development database type to prepare for migration, see Changing the development database type by using the setdbtype command.
DB2Note: When you specify a DB2 password, make sure that it meets the naming restrictions for WebSphere Commerce databases. If restricted characters are used in database passwords, you might encounter connection errors when you use utilities that take these passwords as input on the command-line, including setdbtype.

Some characters might correspond to special characters on certain operating systems and therefore must be escaped. For example, on UNIX, the $ character must be escaped like this character: \$

Before you begin

Consider the following statements before you switch database types:
  • If you are developing session beans or custom entity bean finders that have database-specific SQL statements, you should consider moving to one of the other supported databases. The alternative is to code your session beans and custom finders to examine the useCloudscape, useDB2, and useOracle methods of the BaseJDBCHelper class and then generate the database specific SQL statements.
  • The effort of maintaining code that will work with Apache Derby and your target database, must be weighed against the additional setup and configuration effort required in setting up development environments that works directly against the target database.
  • As you create a new database or switch your database using the setdbtype command, keep in mind that the Stores Web project assets can be impacted by this change. The Stores Web project contains a configuration file that ties the store_id in the database to the JSP pages of your store. If your existing database does not have the same stores with the same store_id, it is recommended that you make a copy of the WCDE_installdir/workspace/Stores directory and save it with a reminder of which database it is assigned to.
  • DB2 If you are using a remote database, install the appropriate DB2 client to access the remote DB2 database. For more information, see your DB2 documentation.
  • Oracle
    1. If you are using a remote database, install the appropriate Oracle client to access the remote Oracle database. For more information, see the Oracle documentation.
    2. Create a database.
    3. Create an Oracle database user.
      Note: Ensure that the user has enough table space or that Auto Extend is set to Yes in the data file. Grant the user the following privileges: create procedure, create session, create synonym, create table, create trigger, create view, and create materialized view.
  • For information about the supported databases, see Recommended software, fixes, and settings for WebSphere Commerce Version 8.0.