If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > how to get "db2 installation path" from DB2 Command Window?

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 05-26-04, 02:45
grofaty grofaty is offline
Registered User
 
Join Date: Jan 2003
Posts: 1,570
how to get "db2 installation path" from DB2 Command Window?

Hi,

I am writting a script witch will copy some files to SQLLIB\BIN directory on users computers. Users use Windows 2000 or Windows XP. They can have installed db2 v7.2 or db2 v8. So each computer can have different db2 installation path (sample: c:\program files\ibm\sqllib\bin).

I would like to write a script witch the output would be "db2 installation path".
Can I write someting like:
"db2 get installation path"

The output should be someting like:
"c:\program files\ibm\sqllib\bin"

Thanks,
Grofaty

Last edited by grofaty; 05-26-04 at 02:47.
Reply With Quote
  #2 (permalink)  
Old 05-26-04, 03:40
grofaty grofaty is offline
Registered User
 
Join Date: Jan 2003
Posts: 1,570
Hi,

I have found the command db2set
It returs:
DB2INSTPROF=C:\PROGRAM FILES\SQLLIB

Is this db2 installation directory?

Thanks,
Grofaty
Reply With Quote
  #3 (permalink)  
Old 05-26-04, 06:51
Tank Tank is offline
Registered User
 
Join Date: Feb 2004
Location: Copenhagen
Posts: 220
Arrow db2level

Hi Grofaty

I don't think thats your installation directory - but I'm not certain

Running the 'db2level' command from the command line should yield
the necessary information (among other)

HTH
__________________
Kristian K. Hansen
Project Supervisor
National Board of Health
Reply With Quote
  #4 (permalink)  
Old 05-26-04, 07:11
grofaty grofaty is offline
Registered User
 
Join Date: Jan 2003
Posts: 1,570
Hi,

db2level in db2 v7.2 does not include db2 installation directory. My script should work ofr v7.2 and v8.1.

I think db2set is just what I need. I have tested on v7 and v8 and it works fine.

No help is needed.

Thanks,
Grofaty
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On