Tagged Questions
4
votes
1answer
93 views
Designing Simple Schema for Disaggregation of Demand Forecast
I am doing a simple database design task as a training exercise where I have to come up with a basic schema design for the following case:
I have a parent-child hierarchy of products (example, Raw ...
4
votes
1answer
471 views
temporary table inside procedure oracle
I'm in a situation right now. I'm migrating several procedures from Mysql 5.0 to Oracle 11g.
Mysql procedures allow me to:
1. Create temporary tables
2. Insert data into temporary tables / Query these ...
2
votes
1answer
547 views
Oracle error “too many values”, must be solved with nested SELECTs
I have hit upon a "too many values" error in Oracle, when working with some intricate nested SELECTs.
A simplified description of my problem, on a toy problem describing the hierarchy in a company. ...
1
vote
3answers
96 views
Query missing one date; only happened today
This should be pretty reproducible I hope.
I'm on Oracle 11g. This query, which I use as part of another query, is acting strangely:
SELECT TRUNC(SYSDATE - ROWNUM) DATEITEM
...
2
votes
1answer
143 views
ETA: translate Oracle SQL queries to MySQL
task: replace Oracle 11g with MySQL
current setup:
Oracle 11g SE One
about 80 tables
stored procedures, PL/SQL are in place but out of scope for this question
client applications do not use a ...
1
vote
1answer
193 views
Help with getters & setters in PL/SQL
I am not a db guy, and I have a very beginner's knowledge bout PL/SQL. That being clear now the question:
I have 2 tables one file level & another batch level. In a day, only 1 file_id is ...
-4
votes
1answer
1k views
primary key, foreign key relationship between the department and employee tables How do I install? (sql_developer) [closed]
EMPLOYEES TABLE
COLUMN NAMES:
EMPLOYEE_ID
EMPLOYEE_NAME
EMPLOYEE_LASTNAME
JOB
EMPLOYEE_BUSINESS_PHONE
EMPLOYEE_GSM
SALARY
HIRE_DATE
E_MAIL
DEPARTMAN_NO
NOTE:FOR THIS TABLE: EMPLOYEE_ID IS PRIMARY ...
0
votes
1answer
1k views
Oracle SQL for left outer join to rownum = 1 of another query?
Background
I have a query joining many tables together, the chief of which is a workorder table.
I also have a table called WOStatusHistory, which stores every status for every workorder.
A diagram ...
1
vote
1answer
442 views
How do you monitor specific SQL statement of a specific user ?
We have a few standalone users here which cause high server loads for several 11.1.0.7 Oracle's.
I spoke with them a few times but it seems that their queries are causing high loads and probably ...
4
votes
1answer
784 views
How to use the METHOD_OPT parameter in DBMS_STATS.gather_table_stats
Hi there I was just wondering what would be the difference between these 2 METHOD_OPT parameter settings:
FOR COLUMNS SIZE 5 some_column
and
FOR COLUMNS some_column SIZE 5
both will create a ...
6
votes
4answers
5k views
In Oracle how do I save a sequence.nextval in a variable to be reused in multiple inserts?
I'm writing a script to populate some tables with data for testing.
I would like to write something like the following but I don't know how to do it (I'm Oracle 11g)
SET ENABLED_USER_ID = ...
8
votes
2answers
401 views
LNNVL Justification
LNNVL is an oracle built in function that returns TRUE for conditions evaluating to FALSE or UNKNOWN, and returns FALSE for conditions evaluating to TRUE. My question is what would be the benefit of ...
