Hi
We have a requirement in which we need to query data across 2 different databases ( 1 in SQL Server and other in Oracle).
Here are the scenarios which need to be implemented:
Query: Get the data from one database and match for values in other
Update: Get the data from one database and update the objects in other
Technology that...
I'm trying to create a trigger that will do the following.
After insert on Table A, query Table B based on an id (TableA.id=TableB.id) and insert corresponding info into TableA
I have a feeling I'm way off so far so any help would be appreciated
CREATE OR REPLACE TRIGGER myTrig
AFTER INSERT
ON TABLEA
BEGIN
INSERT INTO TABLEA
SELEC...
I've got a synonym pointing to a table:
-- Create the synonym
create or replace synonym my_schema.COLORS_ALL
for OTHER_SCHEMA.MV_CAR_COLORS;
problem is that I can query this synonym fine:
select * from my_schema.COLORS_ALL;
however, when I try to use this synonym in a Stored Proc I get an error that table or view does not exist....
Thanks to the ubiquitous fast Internet, I've gotten in the habit of using Google to search for Java API docs, rather than digging through the online the API docs or the copy I have stored locally for speed. Looking for a class like Pattern (was that in java.util or java.text? If I knew, I wouldn't have to go searching for it!), I just Go...
Is there any solution for this error on Windows 7 64 bit (because I think it's the main cause) in .NET application? (ASP.MVC2 with EF4)
I've:
Windows 7 64 bit
Oracle Express 10g (i've tried to install Client 11g, but then, during installation i got another error - Net Configuration Assist~ Error - something about oraclj11 and java)
...
I'm going to build application using Application Express and Oracle Database Enterprise, VPD Implemented on the schema using Context,
for developer issue I set on login trigger to set user;
but I can't view data inside application but I can view it using SQL statement
So is their issue in Apex when using VPD , Context , or On log on t...
Can anyone share a link to sample (ASP).Net code that uses the new Oracle Data Provider.Net library?
I have code a web application code that uses the System.Data.OracleClient classes and want to migrate to the new Oracle Data Provider for .Net.
Thanks
...
I have the line below in a .sql script. Not sure what it does. Does it wait for input from user for dbuserid and password or does it take the values from environment?
What does && denote? In test.sql file I saee the line below before creating tables:
CONNECT &&usr/&&pass@&&dbname
...
I have the below shell script that calls an sql script. The problem is it calls the sql script, i enter the username,password ,dbname and after that it creates the table
but it doesn't exit from the sql prompt.
test.sh
#!/usr/bin/ksh
sql_test=test.sql
$ORACLE_HOME/bin/sqlplus /nolog @${sql_test}
exit
test.sql
CONNECT &&usr/&&pa...
Hi
Is there a way to replace the last digit with a hyphen and a digit.
original needs to be replaced with
file01 file01-01
file02 file02-02
With AmarGhosh I solved this
with names as
(
select '/file01/some/file01' name from dual
union all
select '/file02/another/file02' name from dual
)
selec...
I have the following inside a package and it is giving me an error:
ORA-14551: cannot perform a DML operation inside a query
Code is:
DECLARE
CURSOR F IS
SELECT ROLE_ID
FROM ROLE
WHERE GROUP = 3
ORDER BY GROUP ASC;
BEGIN
FOR R IN F LOOP
DELETE FROM my_gtt_1;
COMMIT;
INSERT INTO my_gtt_1
...
Design a database to store details about U.S. Presidents and their terms in office. Also, record details of their date and place of birth, gender, and political party affiliation. You are required to record the sequence of presidents so that the predecessor and successor of any president can be identified. Remember Grover Cleveland se...
Hi there,
I'm using an Access over Oracle database system (Basically using Access for the forms and getting into the tables using ADO code) and am trying to update a field in the product table with the value of the same named field in a load table.
The code I am using is:
.CommandText = "UPDATE " & strSchema & ".TBL_CAPITAL_MGMT_PRODUC...
I am running a query that returns me a collection of date objects for months between a certain date range. The query works fine, but is very slow (~2 seconds on my local machine, ~30 in our corporate development environment). Here it is:
SELECT ADD_MONTHS(TO_DATE('200804', 'YYYYMM'), -1+rownum) AS MONTH
FROM all_objects
WHERE ADD_MONTHS...
I have the following statement which compiles fine in my package:
package header:
TYPE role_user_type IS RECORD (
ROLE_ID some_table.ROLE_ID%TYPE,
SUBGROUP some_table.USER_ID%TYPE
);
body:
ROLE_USER_REC MY_PACKAGE.ROLE_USER_TYPE;
SELECT B.USER_ID, B.ROLE INTO ROLE_USER_REC
FROM some_t...
Friends,
I have written the following JavaScript to ascertain which row of an tabular form the user is currently on. i.e. they have clicked a select list on row 4. I need the row number to then get the correct value of a field on this same row which I can then perform some further processing on.
What this JavaScript does is get the i...
I'm inserting a row using an Oracle stored procedure which is configured to use an autonomous transaction. I'd like to insert this record, commit that transaction, and then lock the newly-inserted record so that nobody else can modify it except my current session (in another transaction, obviously, since the one that inserted it is auto...
Query below takes 20 seconds to run. user_table has 40054 records. other_table has 14000 records
select count(a.user_id) from user_table a, other_table b
where a.user_id = b.user_id;
our restriction is that any query running more than 8 seconds gets killed...>_< I've ran explain plans, asked questions here but based on our restrictio...
I'm experiencing some behavior I did not expect. I have a synchronous procedure that is kicked off via PHP/OCI8. At the beginning of the process there is a SELECT...FOR UPDATE NOWAIT
I do NOWAIT because I want users notified immediately with an error message that the process is already running, rather than having their browser wait fo...
I have a large (150m+ row) table, which is partitioned into quarters using a DATE partition key.
When I query the table using something like...
SELECT *
FROM LARGE_TABLE
WHERE THE_PARTITION_DATE >= TO_DATE('1/1/2009', 'DD/MM/YYYY')
AND THE_PARTITION_DATE < TO_DATE('1/4/2009', 'DD/MM/YYYY');
... partition pruning works correctly...