set feedback off

set verify off

set pause off

set termout off

set heading off



variable version varchar2(2000)

variable compatibility varchar2(2000)



execute dbms_utility.db_version(:version, :compatibility);



select 'exit ' || substr(:version, 0, instr(:version, '.')-1) from sys.dual



spool tmpcheckdbversion.sql

/

spool off



set termout on

start tmpcheckdbversion.sql

