152,739 questions
0
votes
0
answers
13
views
Different user's data in apex report
I have installed Oracle 11g R2 in a linux server and created 5 users. Apex version 18.2 installed in the same server, Ords 18.4 Tomcat 8.5 is installed with different port in another server for each ...
0
votes
2
answers
42
views
Get List of Months Between Two Dates
I am attempting to write a query that transforms the following table, where Accrual Length is the number of months between and inclusive of each Activation Date and Accrual End Date.
Institution
...
0
votes
0
answers
16
views
Hibernate spatial custom type is overriden by the default Hibernate spatial type
I have a custom Oracle Hibernate Dialect with a custom Oracle spatial type.
This type is supposed to replace the standard SDOGeometryType.
The purpose of this custom type is to handle complex arcs in ...
0
votes
1
answer
34
views
java.lang.ClassNotFoundException: oracle.jdbc.driver.OracleDriver- while accessing oracle database from jsp
getting error 'java.lang.ClassNotFoundException: oracle.jdbc.driver.OracleDriver' while accessing the database from jsp file.
But it works perfectly when database is accessed from java file. Both ...
0
votes
0
answers
64
views
Oracle SQL Query - Data as a point in time [closed]
I am just writing a query to get data for people that are on secondments, leave, etc at a given point in time.
One of the key requirements is to get all the additional data (position record, manager ...
-2
votes
0
answers
44
views
Ordering values after grouping other values across multiple table joins [closed]
I've been tasked with moving product out of areas where they do not belong into areas where they do belong: piece items out of casepick locations and pack items out of active locations.
I want to sort ...
0
votes
1
answer
38
views
Oracle query - day / time range
Trying to figure out how to write a query where the criteria on the CONNECT_TIME column is only on FRIDAYS 9:00pm - SATURDAYS 1:00am. Everything else can be ignored.
Just not sure how to combine ...
0
votes
1
answer
40
views
Fetch records from table and perform insert/update on the other table
Processing records from TABLE_1 and inserting into the TABLE_2.
Code structure as follow,
try (PreparedStatement ps = conn.prepareStatement("SELECT COL.. from table_1")) {
ps....
0
votes
1
answer
48
views
SQL update column based on another table details
Source table:
customer
category
sales
date
order status
allen
in
200
04-03-2025
Completed
currie
out
300
04-03-2025
WIP
frank
out
400
04-03-2025
WIP
alice
in
500
04-03-2025
WIP
allen
out
400
04-...
-1
votes
0
answers
28
views
Running into ActiveRecord::StatementInvalid: OCIError: ORA-00905: missing keyword (ActiveRecord::StatementInvalid) with join query
Here is the query I am attempting to run on an oracle db (Oracle Database 19c Standard Edition 2 Release 19.0.0.0.0 - Production):
orphan_queries = {
Keyword => [
{ join_table: '...
-4
votes
1
answer
50
views
"Insert record if not present " logic is not working for some request if we hit 100 request per second in Node Express Application
I have made an POC application, where the requeirment is to insert the reocord if ther is no record present in the db. This logic is not working if we hit 100 request per second with same data. For ...
1
vote
1
answer
64
views
Merging of regex and replace
I am using Oracle, but my question is general.
I have a text field like below
:25:3500011-01-3
or
:25:74888332223
There can be 0 or any number of hyphens (-) in between the numbers.
I want to ...
1
vote
1
answer
58
views
Oracle 19c Why we can't loop through ORA-01013 exception (when user cancelled sql)
I found some behavior that I don't understand and I can't find it in the documentation. Maybe one of you can explain to me what happened here?
What I want to achieve is to catch an exception when the ...
0
votes
1
answer
34
views
HOW to convert raw column in oracle to string
I want to convert raw col in my table to its real value data
I have raw column in my table contains many column ( char ,varchar2,number, date)
how can extract this data as its real value;
nothing ...
0
votes
2
answers
53
views
Oracle timestamps for ETL delta loading
I'm running an ETL job against an Oracle database. We are passing epoch milliseconds, and the timestamp column in the source is US Eastern and naive.
My query is simple in theory:
SELECT *
FROM table
...
0
votes
4
answers
67
views
Get max value of multiple columns
I have data that is denormalized and I want to grab the the column for each person where there is a value in the max column. If there is a value for Jump2 there will be a value for Jump1; there will ...
2
votes
2
answers
72
views
Blending 2 tables in SQL Oracle
I am attempting to blend 2 tables together using an Oracle Select statement. Unfortunately, I lack privileges to create tables or procedures.
One is a table with 2 rows and 2 columns and each cell has ...
-1
votes
0
answers
16
views
Oracle Check Multiple Fields in a Query for 2 Specific Values and return them as a 1 or 0 if found as a new column
Working with Multiple Sets of Nested grouping data in an Oracle Query for an existing Report.
Including the Top 2 Queries as that's where the need will be :
The Calculated Field Is MAX_LEVEL and is ...
1
vote
1
answer
24
views
how json_table is joined with another table in Oracle database?
In https://oracle-base.com/articles/19c/sql-nested-clause-instead-of-json_table-19c
the following query
SELECT j.id, jt.first_name, jt.last_name, jt.job, jt.email, jt.phone, jt.active
FROM ...
0
votes
1
answer
40
views
Oracle create program
I found this as an option to create an Oracle program where SQL code could be inserted; however, the syntax does not allow me to create this. The SQL code is not seen as valid in the program action ...
0
votes
1
answer
62
views
how to select precisely column created on dual table [duplicate]
i created a dummy table using dual in Oracle. If i execute this script using * to select all the lines, no problem it work. But when i try to select one named column, i have a problem who apparear :
*
...
0
votes
0
answers
14
views
Can I browse table data in Oracle Fusion?
I'm creating reports in OTBI and in order to see the data I am creating a data model, writing select * for a given table and then viewing the sample date.
Is there an easier way to do this? I would ...
-4
votes
1
answer
55
views
Read Column Data from Table [closed]
CREATE TABLE TEST(COL_A VARCHAR2(100),COL_B VARCHAR2(100));
INSERT INTO TEST VALUES('A','ABC');
INSERT INTO TEST VALUES('A','CDE');
INSERT INTO TEST VALUES('B','CDE');
INSERT INTO TEST VALUES('B','...
0
votes
0
answers
31
views
Should I add direct indexes on GUID columns or RAWTOHEX forms, when I'm interacting database from Hibernate?
I have two experimental tables T_PARENT_TEST and T_CHILD_TEST (each with ~ 555000 rows) with the following DDLs:
create table T_PARENT_TEST
(
ID RAW(16) default SYS_GUID() not null
...
-1
votes
1
answer
56
views
MERGE statement not deleting record
MERGE INTO EMPLOYEES_COPY EC
USING EMPLOYEES E ON (E.EMPLOYEE_ID = EC.EMPLOYEE_ID)
WHEN MATCHED THEN
UPDATE SET EC.JOB_ID = E.JOB_ID WHERE EC.EMPLOYEE_ID <> 102
DELETE WHERE EC....
3
votes
2
answers
63
views
Oracle database - invalid identifier (that is not even part of the SQL query)
I use the QueryRunner to execute SQL commands on the Oracle database.
QueryRunner queryRunner = new QueryRunner();
int result = queryRunner.update(this.conn, "UPDATE system_user SET ...
-3
votes
0
answers
16
views
administrateur de base de données [closed]
Gestion des Schémas Utilisateurs –Rôles– Privilèges – Profiles
0
votes
1
answer
73
views
Oracle create function fails in "SQLPro for Oracle"
I am creating this very simple function in Oracle 23ai using the client SQLPro for Oracle, which is not being compiled due to errors.
create or replace function test_func (data1 varchar2, data2 ...
-2
votes
0
answers
36
views
İ can not sign in Oracle free tier for created Oracle apex workspace [closed]
I want to create an account in Oracle free tier. After filling in all the required fields (payment section is successfully filled), I click on the verify email button. A message comes to my Gmail ...
0
votes
1
answer
41
views
PL/SQL JSON_OBJECT_T error Code: -40573 - ORA-40573: Invalid use of PL/SQL JSON object type
I'm trying to build one PL/SQL stored procedure to insert update delete data into the table using below procedure but it is failing with the error Error Code:
-40573 - ORA-40573: Invalid use of PL/...
0
votes
4
answers
47
views
Find records which having the Flag value Y and other records with Flag value N
Below is the sample table
Rec_ID
Flag_Val
4322
Y
2643
Y
9733
N
4322
N
9733
Y
1979
N
The SELECT SQL need to fetch Rec_IDs 4322, 9733 from the table. If any Rec_ID's flag value is 'Y' and the ...
0
votes
0
answers
11
views
ROLLUP usage in Oracle Data Integrator (ODI)
I have an insert statement like;
INSERT INTO table
(column1, column2, column3 )
SELECT fact_1_id,
fact_2_id,
SUM(sales_value) AS sales_value
FROM dimension_tab
GROUP BY ROLLUP (...
0
votes
1
answer
45
views
Why Godror make Oracle ACL recognizes the program name as `main@<hostname> (TNS V1-V3)`?
I am working on a Go project that connects to an Oracle database using the godror driver. The Oracle DB has an ACL that includes the program name. However, the K8s pods with some replicas cannot fix ...
0
votes
2
answers
46
views
Oracle Partition in For Loop Select
I need to fetch all rows in a specific partition of a table and print the values to a file.
CREATE OR REPLACE PROCEDURE
WriteRecordToFile
(
mypartition IN VARCHAR2,
myfilename IN VARCHAR2,
...
0
votes
0
answers
29
views
select from with data separate for comma in Oracle DB [duplicate]
Good afternoon, I am currently doing a query of an SQL table and I want to bring an entire table (select * from) in values separated by commas, I have already managed to get it to come on a single ...
-1
votes
0
answers
25
views
error in the web service logs OCIEnvCreate failed with return code -1 but error message text was not available [closed]
Good afternoon. I have just started my career in Administration. I'll let you know right away, English is not my native language, so I'm sorry for the mistakes. I've been assigned a task that I haven'...
-2
votes
2
answers
66
views
Columns to rows in SQL [duplicate]
I have a table abc:
create table abc
(
column_a varchar2(100),
column_b varchar2(100)
);
insert into abc values ('a', 'b,c,d,e');
commit;
I want to see the data in rows.
Column_a would have ...
0
votes
2
answers
71
views
PL/SQL PLS-00302 component must be declared
I'm trying to build a PL SQL code for generating a DML script given a table.
I loop through your typical employee mock table to test it.
But every time I get this error message:
PL/SQL PLS-00302 ...
0
votes
0
answers
30
views
Oracle 19c and Pro*C: array fetching from a cursor behaving weirdly when using aggregate functions
TOOLS: I'm using Pro*C under Oracle 19c and the pc files have been parsed using parse=partial code=c++ char_map=string as command line options.
Take the following example, with some fictional main ...
1
vote
1
answer
43
views
Oracle user_updatable_columns says the column is not updatable but it is
I am confused with updatable views. As an example, let's say we have a simple schema that records customers and their accounts:
create table test_customer(
customer_id number(2),
customer_name ...
2
votes
0
answers
20
views
alter table modify option to remove partitioning completely?
Oracle allows easy redefinition of partitioning schemes with the syntax alter table XYZ modify partition by ... which simplifies the task of either converting a non-partitioned table to a partitioned ...
0
votes
1
answer
60
views
Reading large data from table & sending output in json
database is 19C
I'm trying to read 10k+ records from Oracle table[with 2 columns in this case], convert records to JSON and return the result via procedure in CLOB.
e.g. table CODES_CLASS, columns ...
0
votes
1
answer
26
views
Is there a way I can expand a query if one value is null in Oracle SQL?
Is there a way that I can expand an existing table into something like a view, replacing the (null) value with multiple records? Basically, (null) represents that the user has access to all the roles ...
0
votes
0
answers
23
views
ORA-20000: ORA-24247: Network access denied by access control list (ACL) [closed]
set serveroutput on size unlimited;
SELECT DBMS_CLOUD_AI.GENERATE(
prompt => 'what is oracle autonomous database',
profile_name => 'GENAI',
action => 'chat')
FROM dual;
ORA-...
0
votes
1
answer
34
views
Updating the datatype of a column in an Oracle database
I am trying to modify a column in a table in Oracle to reduce the precision from number(5) to number(2) and I am getting this error.
ORA-01440 - column to be modified must be empty to decrease ...
1
vote
1
answer
38
views
For Oracle DB. looking to store a value from a select statement into a variable to use in a later query
I need to use two IDs from my select statement so I can make other statements retrieving data from another table. I'm using a data model in Oracle BI Publisher.
select
a.dist_code_combination_id,
a....
1
vote
1
answer
42
views
Recursive query where parent can be in another table and allowing multiple children
I have 2 tables:
TABLE A:
A_ID
TABLE B:
B_ID; LINKS_TO_A_ID; LINKS_TO_B_ID
They are supposed to represent a chain of actions, where the top of the chain can start both at Table A or Table B (but ...
-1
votes
1
answer
42
views
how do use dropdown menu on oracle-apex [closed]
ok so in my persons table , the organization_id is a foreign key referencing the restaurant_id(from the restaurant table ) , supplier_id ( from the suppliers table) as well as company_id (from ...
0
votes
2
answers
54
views
Oracle Sequence in MERGE Statement
How to use SEQ in MERGE?
merge into tab_a tgt using
(Select col1,col2,seq
from tab_a f) src
on
(joinin condition)
when matched then update
set
tgt.seq = src.seq;
It is showing
Sequence number ...
0
votes
1
answer
96
views
Use AND and OR within where clause for dates
I need to filter a collection of records that satisfies a single date OR satisfies a range of dates. How is this done in conjunction? For example, I need to filter records that has the date 02-FEB-24 ...