Search the Reference Library pages:  

Oracle ENVIRONMENT VARIABLES
Version 11.1
 
Product Homes
Query to identify home directories for Oracle products
set linesize 131
set pagesize 20
col host_name format a30
col home_name format a20
col home_location format a50

SELECT *
FROM sysman.mgmt$software_homes;
 
Release Number
Release Number Demo
SELECT &_O_RELEASE FROM dual;
 
SQL%ROWCOUNT

Update Demo
CREATE TABLE t (
testcol VARCHAR2(10));

INSERT INTO t (testcol) VALUES ('ABCDEFG');
INSERT INTO t (testcol) VALUES ('ABCXEFG');
INSERT INTO t (testcol) VALUES ('ABCYEFG');
INSERT INTO t (testcol) VALUES ('ABCDEFG');
INSERT INTO t (testcol) VALUES ('ABCZEFG');
COMMIT;

BEGIN
  UPDATE t
  SET testcol = 'UPDATED'
  WHERE testcol LIKE '%D%';

  IF SQL%ROWCOUNT = 0 THEN
    INSERT INTO t
    (testcol)
    VALUES
    ('12345567');
  END IF;
END;
/

BEGIN
  UPDATE t
  SET testcol = 'UPDATED'
  WHERE testcol LIKE '%S%';

  IF SQL%ROWCOUNT = 0 THEN
    INSERT INTO t
    (testcol)
    VALUES
    ('0000000');
  END IF;
END;
/
 
Related Topics
DBMS_SYSTEM.GET_ENV
Exception Handling
System Events
 
   Home |    Search |    Code Library |    Sponsors |    Privacy |    Terms of Use |    Contact Us    © 2003 - 2024 psoug.org
-----