cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

db2 commands

Former Member
0 Likes
3,329

hi ,

I am new to db2 database

I have the following query

1.) How can we check the scheme owner of the db2 database .

2.) I wanted to reset the DDIC passsword from the database command prompt , can anybody give me the syntax of the command.

3.) How to connect to db2 database from command prompt.

Regards

Anthony

Edited by: Anthony D'souza on Jun 3, 2008 1:33 PM

View Entire Topic
Former Member
0 Likes

1. After connecting to database, the following will give schema name and owner.

db2 "select schemaname,owner from syscat.schemata"

2. DDIC password reset - Do not know. Let you know if I find.

3. Connecting to db2 database depends on from where the connection is coming from like local or remote....so on....

As local

db2 connect to dbname -- this will connect as db2<sid> user

to connect as different user like sap<sid>

db2 connect to dbname user sap<sid> -- it will prompt for sap<sid> user password

As remotely i.e from db2 client (pre-requisite is that particular db need to catalogued at local client)

db2 connect to dbname user sap<sid> -- it will prompt for sap<sid> user password

Former Member
0 Likes

Could you give the syntax for catalogue the remote DB?

Thanks!

Former Member
0 Likes

Catalog node first on remote client

[CATALOG TCP/IP NODE|http://publib.boulder.ibm.com/infocenter/db2luw/v9/topic/com.ibm.db2.udb.admin.doc/doc/r0001944.htm]

next

[CATALOG DB|http://publib.boulder.ibm.com/infocenter/db2luw/v9/topic/com.ibm.db2.udb.admin.doc/doc/r0001936.htm]

Another way is using IBM DB2 Congiguration Assistant tool