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 > Get versionnumber

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 06-14-11, 08:12
I_am_Joker I_am_Joker is offline
Registered User
 
Join Date: Jun 2011
Posts: 4
Get versionnumber

Hi you all,

I need to know the DB2 versionnumber and all the extra interesting information about several DB2 databases. I am connecting through ODBC from C# and I need to use a query to gather the required information.

Probably this question has already been launched on this website over a million times, but still ...

Can anyone help me out here?
Reply With Quote
  #2 (permalink)  
Old 06-14-11, 09:03
n_i n_i is offline
:-)
 
Join Date: Jun 2003
Location: Toronto, Canada
Posts: 4,449
Depends on the DB2 version.

In 9.x: views SYSIBMADM.ENV_INST_INFO and SYSIBMADM.ENV_PROD_INFO

In 8.x, starting with fixpak 9: functions SYSPROC.ENV_GET_INST_INFO() and SYSPROC.ENV_GET_PROD_INFO()

Prior to that this information was not accessible using SQL.
Reply With Quote
  #3 (permalink)  
Old 06-15-11, 06:17
I_am_Joker I_am_Joker is offline
Registered User
 
Join Date: Jun 2011
Posts: 4
Get Version number

Hi n_i,

I queried on several databases the query
Code:
SELECT * FROM SYSIBM.views ORDER BY table_name
and got nothing starting with 'ENV_'.

I queried on several databases the query
Code:
SELECT * FROM SYSIBM.sqlfunctions ORDER BY function_name
and got nothing starting with 'ENV_'.

Even querying
Code:
SELECT * FROM SYSIBM.SCHEMATA ORDER BY schema_name
didn't get me a SYSIBMADM schema. The best next thing I have, is a SYSIBM. I do have a SYSPROC schema.

What's next?
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