Re: SQLPlus version tracking

From: Yong Huang <yong321_at_yahoo.com>
Date: Fri, 20 Jan 2012 14:57:03 -0800 (PST)
Message-ID: <1327100223.73860.YahooMailClassic_at_web181216.mail.ne1.yahoo.com>



> With some experiment, I think the widths of the numbers are
> 2, 1, 2, 1, 2 bytes, respectively. So we can use the
> following SQL to check the client version (run as sys):
> ...

A better SQL for an 11g database to check its client version:

with x as (select distinct to_char(ksuseclvsn,'xxxxxxx') v  from x$ksusecon where ksusenum = &sid)
select decode(v, ' 0', '10g or lower',

 to_number(substr(v,1,2),'xx') || '.' || --maj_rel
 to_number(substr(v,3,1),'x') || '.' || --mnt_rel
 to_number(substr(v,4,2),'xx') || '.' || --ias_rel
 to_number(substr(v,6,1),'x') || '.' || --ptc_set
 to_number(substr(v,7,2),'xx')) client_version -- port_mnt
from x;

Have a good weekend!

Yong Huang

--
http://www.freelists.org/webpage/oracle-l
Received on Fri Jan 20 2012 - 16:57:03 CST

Original text of this message