By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,514 Members | 1,702 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,514 IT Pros & Developers. It's quick & easy.

How can I connect to SAMPLE database?

P: 8
I installed IBM DB2 Database for Window (Ver. 9) before.
Meanwhile, I installed the database SAMPLE.
Because I forgot my password, I uninstalled later on.

Several days ago, I reinstalled again. When I try to connect to sample database (db2 => connect to sample user db2admin), it shows,

SQL1013N The database alias "SAMPLE" could not be found. SQLSTATE=42705

However, when I tried to get back to reinstalled SAMPLE database from my installed program (db2exc_91_win_x86, same as what I used at the first time installation), the error message comes up as following,

Existing "SAMPLE" option was not specified...
Attempt to create the database "SAMPLE" failed...
SQL1005N The database alias "SAMPLE" already exists either the local database directory or system database directory.

So, how can I found the existing SAMPLE database? How can I connect to them?

Thanks, everybody.

Cheers,
Feb 28 '07 #1
Share this Question
Share on Google+
6 Replies


10K+
P: 13,264
I installed IBM DB2 Database for Window (Ver. 9) before.
Meanwhile, I installed the database SAMPLE.
Because I forgot my password, I uninstalled later on.

Several days ago, I reinstalled again. When I try to connect to sample database (db2 => connect to sample user db2admin), it shows,

SQL1013N The database alias "SAMPLE" could not be found. SQLSTATE=42705

However, when I tried to get back to reinstalled SAMPLE database from my installed program (db2exc_91_win_x86, same as what I used at the first time installation), the error message comes up as following,

Existing "SAMPLE" option was not specified...
Attempt to create the database "SAMPLE" failed...
SQL1005N The database alias "SAMPLE" already exists either the local database directory or system database directory.

So, how can I found the existing SAMPLE database? How can I connect to them?

Thanks, everybody.

Cheers,
You did not delete the conatiners and nodes for the database when you uninstalled it. You might have to just create another database with a different name. If you still want to work with the name Sample for the database, you might have to uninstall the DB2 (make sure you delete all files including those in my documents) and install again
Mar 1 '07 #2

P: 8
Thanks sir. Indeed, like you said, after I uninstalled it, I did not delete the conatiners and nodes for the database when I uninstalled it.

So, after I deleted all the files in C:/Program Files/IBM after I did uninstall process and deleted C:/DB2, the default instance when I installed the DB2, the reinstall the SAMPLE database is successful this time.

Thank you very much.

Cheers,
Mar 1 '07 #3

P: 1
Thanks! This has helped me too.
Sep 25 '07 #4

10K+
P: 13,264
Thanks! This has helped me too.
Good to know
Sep 25 '07 #5

P: 1
No. You do not need to reinstall it. Only one sentence could solve this problem:
Db2 catalog db sample as sample
Please refer to this page:http://www.databaseskill.com/3166676/
I search this result for a long time. Finally, I make it!
Oct 5 '15 #6

P: 1
Thanks sir! That really help me
Nov 30 '15 #7

Post your reply

Sign in to post your reply or Sign up for a free account.