I am working on a test server with an Oracle 11g installed. I was wondering if there is anyway I can replicate the database(environment + data) on my local Linux machine. I am using a CentOS 5.3 on Windows XP with SUN Virtual Box. On Windows I am using sqldeveloper client to connect to the 11g database.
...
i do export of an tablespace. This tablespace contains table1 with two rows say rowa and rowb/
now i delete rowb and insert new rowc into this tablespace.
Now i do import of this tablespace.
after importing i see the table1 in tablespace contains
rowa, rowb,rowc but it was suppose to contain rowa and rowb.
Can anybody tell why is thi...
I would like to synchronize access to a particular insert. Hence, if multiple applications execute this "one" insert, the inserts should happen one at a time. The reason behind synchronization is that there should only be ONE instance of this entity. If multiple applications try to insert the same entity,only one should succeed and other...
Problem
There are data gaps that need to be filled. Would like to avoid UNION or PARTITION BY if possible.
Query Statement
The select statement reads as follows:
SELECT
count( r.incident_id ) AS incident_tally,
r.severity_cd,
r.incident_typ_cd
FROM
report_vw r
GROUP BY
r.severity_cd, r.incident_typ_cd
ORDER BY
r.severity_...
As part of our build process and evolving database, I'm trying to create a script which will remove all of the tables and sequences for a user. I don't want to do recreate the user as this will require more permissions than allowed.
My script creates a procedure to drop the tables/sequences, executes the procedure, and then drops the...
I need execute an sql query in ORACLE it takes a certain amount of time.
so i wrote this function
CREATE OR REPLACE FUNCTION MYSCHEMA.TEST_SLEEP
(
TIME_ IN NUMBER
)
RETURN INTEGER IS
BEGIN
DBMS_LOCK.sleep(seconds => TIME_);
RETURN 1;
EXCEPTION
WHEN OTHERS THEN
RAISE;
RETURN 1;
END TEST_SLEEP;
and i call in this way
...
I am Loading large no of rows into a table from a csv data file . For every 10000 records I want to update the indexs on the table for optimization (update statistics ). Any body tell me what is the command i can use? Also what is SQL Server "UPDATE STATISTICS" equivalent in Oracle.is Update statistics means index optimization or gatehri...
Using Oracle 11g release 2, the following query gives an ORA-01790: expression must have same datatype as corresponding expression:
with intervals(time_interval) AS
(select trunc(systimestamp)
from dual
union all
select (time_interval + numtodsinterval(10, 'Minute'))
from intervals
where time_interval < systimestamp)
sel...
Using the Oracle Data Provider for .NET, my application connects to the database using the privileged SYS user. The connection string is as follows:
Data Source=MyTnsName;User ID=sys;Password=MySysPassword;DBA Privilege=SYSDBA
This works fine with Oracle 10, but Oracle 11 keeps complaining about an invalid username or password. I veri...
Friends,
If I want to know about the new features of Oracle 11gR2 Database I can use the New Features Guide.
Is there such a guide that lists functionality, features, parameters etc. that I should no longer be using because they have been superseded or deprecated?
If there isn't such a guide, which I suspect, what do you do to find ...
Hi just installed oracle 11g
and tried to start the "Oracle SQL developer" so as to start writing queries.
Its asking me
Enter the full pathname for the java.exe file .
Where do i find this. I did a global search for java.exe and am sure did not got some oracle related pdf files.
Also my Oracle is installed out of users/vas
...
I'm writing some JDBC code which calls a Oracle 11g PL/SQL procdedure which has a Custom Object return type. Whenever I try an register my return types, I get either ORA-03115 or PLS-00306 as an error when the statement is executed depending on the type I set. An example is below:
PLSQL Code:
Procedure GetDataSummary (p_my_key IN ...
I am working with two instances of an Oracle database, call them one and two. two is running on better hardware (hard disk, memory, CPU) than one, and two is one minor version behind one in terms of Oracle version (both are 11g). Both have the exact same table table_name with exactly the same indexes defined. I load 500,000 identical row...
The following database view rounds the date back to the closest fiscal year (April 1st):
CREATE OR REPLACE VIEW FISCAL_YEAR_VW AS
SELECT
CASE
WHEN to_number(to_char(SYSDATE, 'MM')) < 4 THEN
to_date('1-APR-'||to_char(add_months(SYSDATE, -12), 'YYYY'), 'dd-MON-yyyy')
ELSE
to_date('1-APR-'||to_char(SYSDATE, 'YYYY'...
How would you update data in multiple tables using a single query?
MySQL Example
The equivalent code in MySQL:
UPDATE party p
LEFT JOIN party_name n ON p.party_id = n.party_id
LEFT JOIN party_details d ON p.party_id = d.party_id
LEFT JOIN incident_participant ip ON ip.party_id = p.party_id
LEFT JOIN incident i ON ip.incident_id = i.i...
Hi,
I am new to PL/SQL, I'm trying to execute the commands that I learned at the course.
VARIABLE area NUMBER
DECLARE
radius NUMBER(2) := &s_radius;
pi CONSTANT NUMBER := 3.14;
BEGIN
:area := pi * radius * radius;
END;
I understand that I can run this using SqlPlus, but I remember my teacher was running this from the web brows...
When inserting a large number of rows into a single table hash cluster in Oracle, it will fill up the block with any values that hash to that hash-value and then start using overflow blocks.
These overflow blocks are listed as chained off the main block, but I can not find detailed information on the way in which they are allocated or c...
We are designing database schema for a new system based on Oracle 11gR1. We have identified a main schema which would have close to 100 tables, these will be accessed from the front end Java application.
We have a requirement to audit the values which got changed in close to 50 tables, this has to be done every row.
Which means, it is...
i forget username and password for oracle 11g.so how to get these username and password?
please help me.
...
Hi,
I found out that Oracle Database 10g and 11g treat the following PL/SQL block differently (I am using scott schema for convenience):
DECLARE
v_ename bonus.ename%TYPE;
BEGIN
SELECT b.ename
INTO v_ename
FROM bonus b
JOIN emp e ON b.ename = e.ename
JOIN dept d ON d.deptno = e.deptno
WHERE b.ename = 'Scott'
...