JSON_MERGEPATCH function is very useful to update JSON nodes in JSON documents. We can simply pass the JSON required JSON patch to merge with the existing JSON document using the…
Copy CodeCopiedUse a different BrowserSELECT a.osuser, a.sid, b.os_user_name, b.oracle_username, b.session_id, c.object_name, c.object_type FROM v$session a, v$locked_object b, dba_objects c WHERE a.sid = b.session_id AND b.object_id = c.object_id AND c.object_name =…
PL/SQL provides three collection types − Index-by tables or Associative array Syntax TYPE type_name IS TABLE OF element_type [NOT NULL] INDEX BY subscript_type; table_name type_name; Example TYPE l_tab_type IS TABLE…
How to get Distinct/Unique record without using DISTINCT SQL/Oracle? Create table using following script: Copy CodeCopiedUse a different BrowserCREATE TABLE test_emp ( ename VARCHAR2 (10 BYTE), deptno NUMBER (2), id…
How to save table images to oracle directory? Files from table to Oracle directory Copy CodeCopiedUse a different BrowserDECLARE l_file UTL_FILE.file_type; l_buffer RAW (32767); l_amount BINARY_INTEGER := 32767; l_position INTEGER…
Oracle NULLIF() Function: The Oracle NULLIF() function accepts only two arguments. If the both arguments are equal it returns a null value. In case the arguments are not equal, the…
How to delete duplicate record From table using SQL/Oracle? Create table using following script: Copy CodeCopiedUse a different BrowserCREATE TABLE TEST_EMP ( ENAME VARCHAR2(10 BYTE), DEPTNO NUMBER(2), ID NUMBER )…
How to check duplicate record in table SQL/Oracle? Create table using following script: Copy CodeCopiedUse a different BrowserCREATE TABLE TEST_EMP ( ENAME VARCHAR2(10 BYTE), DEPTNO NUMBER(2), ID NUMBER ) Run…
Oracle NVL2 Function: NVL2() function is an extend version of the NVL() function with different options based on whether a NULL value exists. Oracle NVL2() function allow three parameters. If…
Oracle NULL-Related Functions. There are different type of null related function in oracle. NVL NVL function will check whether the first input parameter is null, if its null value, it…