Sunday, 15 June 2014

How to get and change the current schema

How to get and change the current schema

Command to get and change the current schema you are logged in
Sometimes, if you want to know which schema you are using, you can issue the command:
$db2 values current schema

The output is the following:

$ db2 values current schema

1                                                                               
-------------------------------------------
DB2INST2                                                                        

  1 record(s) selected.

To change the current schema issue the following command:

db2 set schema <SchemaName>

No comments:

Post a Comment