create or replace trigger USER_LOGON after logon on database declare p varchar2(2000); begin select program into p from v$session where sid=(select distinct sid from sys.v_$mystat); if p ='' or p is null or upper(p) like upper('%rwrbe60%') then execute immediate 'alter session set cursor_sharing=EXACT'; end if; end USER_LOGON;