You can create and designate a DB2® user in IBM® DB2 that the IMS Server can
use to connect to the database. This task is optional.
Before you begin
Log on to the database server with administrator privileges.
About this task
This task is optional.
The DB2 user account you create must have privileges
to connect to the database, create tables, and create packages. A
common user name is db2admin, but you can assign
any user name as long as the account has administrative access. Avoid
changing the user name after creating it.
Procedure
- Create an operating system user with administrative
privileges (member of the local administrators group). For
example: imsdb2admin.
- Use one of the following methods to create
and assign DB2 privileges to
the user:
- Use the DB2 Control
Center:
- Open DB2 Control Center.
- If the Control Center View is displayed,
select Advanced.
- Click OK.
- In Object View, expand the object tree for the IMS Server database
that you are authorizing a user to use. Expand the object tree until
you find the User and Group Objects folder.
- Click User and Group Objects.
- Right-click DB Users.
- Click Add.
- In Users, specify the user account
that was created in step 1.
For example: imsdb2admin.
- In the Authorities field, select the following
check boxes:
- Connect to database
- Create tables
- Create packages
- Click OK.
- Use the DB2 command
line processor to execute the following SQL statement.
Note: Before
executing the SQL statement, replace the variables in the SQL statement
with your values.
connect to <ims database>;
grant createtab,bindadd,connect on database to user <DB2 user>;
connect reset;
For example: The following SQL statement
grants the necessary privileges for the database
imsdb to
the user
imsdb2admin:
connect to imsdb;
grant createtab,bindadd,connect on database to user imsdb2admin;
connect reset;