The following are the differences in built-in advanced functions in Oracle (noted only where different):
- USER or sys_context('USERENV', 'SESSION_USER') instead of CURRENT_USER
- SELECT USER from dual;
- SELECT sys_context('USERENV', 'SESSION_USER') from dual;
- sys_context('USERENV', 'CURRENT_SCHEMA') instead ofDATABASE()
- SELECT sys_context('USERENV', 'CURRENT_SCHEMA') from dual; To learn more about the Oracle sys_context function, see the Further reading section in this chapter.
- SELECT * FROM v$version WHERE banner LIKE 'Oracle%'; instead of VERSION()
- CAST—Oracle has different data types you can cast to and from. To learn more about the Oracle CAST function, see the Further reading