Sql Developer: The network adapter could not establish the connection
I am not able to connect my Oracle Database to SQL Developer.
Create date periods based on two tables
CREATE TABLE “TEST1” ( “ID” NUMBER(9,0) NOT NULL ENABLE, “DATE_FROM” DATE, “DATE_TO” DATE ); CREATE TABLE “TEST2” ( “ID” NUMBER, “PERCENT” NUMBER(5,4), “DATE_FROM” DATE ); insert into test1 (ID, DATE_FROM, DATE_TO) values (546, to_date(’01-12-2005′, ‘dd-mm-yyyy’), to_date(’01-12-2006′, ‘dd-mm-yyyy’)); insert into test1 (ID, DATE_FROM, DATE_TO) values (546, to_date(’01-12-2006′, ‘dd-mm-yyyy’), to_date(’01-07-2011′, ‘dd-mm-yyyy’)); insert into test1 (ID, DATE_FROM, DATE_TO) […]
ORA-00937 when reading a group by subquery
I am relatively new to Oracle Db, and this might be something stupid, but I cannot find what is the problem with this query. I get ORA-00937: not a single-group group function when I run it.
Generate Nested JSON oracle19c using JSON functions
Hi I have below sample query.In real case scenario there are many more columns in each view.
The A view has unique ids and is present in other views. I tried to join all the views and generate JSON using JSON_OBJECT and JSON_ARRAYAGG but the join is causing duplicates in my final JSON.
I tried creating separate JSON array and was thinking of merging but could not make it work. Below is the sample CTE for the data. Basically the 3 views are JSON_OBJECT inside ARRAY.
If there is not data in B,C,D views for the matching ID in A then there will be no JSON object for that view example 301 is not present in D view.
Only allow same value in column after first Insert
I am trying to create a trigger that only allows the user to insert the same value into a column after the first insert has been made. For example in the table below the user has entered Name = Jake and age = 29.
DBA_SEGMENTS don’t show my new partition table information on oracle 19c
We have a new partition table. I wanted to get the, each sub partition size in GB.
But, couldn’t find these anything related to partition table in dba_segments.