Solved

How do I create a user with DBA permissions in DB2 similar to in Oracle - create user user1 identified by user1;grant dba to user1;grant connect to user1;

Posted on 2008-10-12
9
2,546 Views
Last Modified: 2013-12-07
How do I create a user with DBA permissions in DB2 similar to in Oracle - create user user1 identified by user1;grant dba to user1;grant connect to user1;
0
Comment
Question by:smahadevappa
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
  • 2
  • +1
9 Comments
 
LVL 16

Accepted Solution

by:
Peter Kwan earned 250 total points
ID: 22700344
db2admin create /user:user1 /password:user1
db2admin setid user1
GRANT DBADM ON DATABASE TO USER user1

0
 

Author Comment

by:smahadevappa
ID: 22700373
hi
tried

a) was logged in as admin adn tried create /user:user1 /password:user1

b) db2admin create /user:user1 /password:user1

both say not a valid DBA command.



below you can find error message.

create /user:user1  /password:user1
DB21034E The command was processed as an SQL statement because it was not a
valid Command Line Processor command. During SQL processing it returned:
SQL0104N An unexpected token "create" was found following
"BEGIN-OF-STATEMENT". Expected tokens may include: "SELECT". SQLSTATE=42601
db2 => db2admin create /user:portalCS71SP1 /password:portalCS71SP1
DB21034E The command was processed as an SQL statement because it was not a
valid Command Line Processor command. During SQL processing it returned:
SQL0104N An unexpected token "db2admin" was found following
"BEGIN-OF-STATEMENT". Expected tokens may include: "<values>".
SQLSTATE=42601

Is there anything else I need to do ?
0
 
LVL 16

Expert Comment

by:Peter Kwan
ID: 22700391
can you try to create the user account in the OS?
0
NEW Veeam Agent for Microsoft Windows

Backup and recover physical and cloud-based servers and workstations, as well as endpoint devices that belong to remote users. Avoid downtime and data loss quickly and easily for Windows-based physical or public cloud-based workloads!

 

Author Comment

by:smahadevappa
ID: 22700414
Hmm.. I am not aware of creating user in AIX where I can set privileges to DB2 user.

Letting me know how to do will be helpfull.

0
 
LVL 45

Expert Comment

by:Kent Olsen
ID: 22701590
Your unix administrator (someone with access to the *root* account) should be able to create the user(s) for you.

Then it's just a matter of executing the GRANT statement.


Kent
0
 
LVL 37

Assisted Solution

by:momi_sabag
momi_sabag earned 250 total points
ID: 22703013
try to issue the above commands but not from within the command line processor
just use a plain shell of your use and issue the above commands
0
 
LVL 45

Expert Comment

by:Kent Olsen
ID: 22703150
Good catch, momi.

  :)


0

Featured Post

Salesforce Has Never Been Easier

Improve and reinforce salesforce training & adoption using WalkMe's digital adoption platform. Start saving on costly employee training by creating fast intuitive Walk-Thrus for Salesforce. Claim your Free Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This post first appeared at Oracleinaction  (http://oracleinaction.com/undo-and-redo-in-oracle/)by Anju Garg (Myself). I  will demonstrate that undo for DML’s is stored both in undo tablespace and online redo logs. Then, we will analyze the reaso…
When it comes to protecting Oracle Database servers and systems, there are a ton of myths out there. Here are the most common.
This video shows setup options and the basic steps and syntax for duplicating (cloning) a database from one instance to another. Examples are given for duplicating to the same machine and to different machines
This video shows syntax for various backup options while discussing how the different basic backup types work.  It explains how to take full backups, incremental level 0 backups, incremental level 1 backups in both differential and cumulative mode a…

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question