SQL & PL/SQL :: Mirroring A Table With Exclusive Column?

Sep 16, 2010

there's a table with 3 columns oid, value, status in a scheme. Now i want this table to be used in an other scheme. So i used grant select to the other scheme so it could read the data. But now i want the column status for independent use of updates in the 2nd scheme. So i want the columns oid & value in one place (table in 1st scheme) and 2 places for status (in original table and in the 2nd scheme. I could create a status table in scheme 2 with oid and status and create an updatable view over table from scheme 1 and this status table - joined over oid. Sounds not too tough but if data is inserted in scheme 1 (all 3 colums) the status table in scheme 2 has no idea of this new data.I want to prevent using triggers or notifications.

View 23 Replies


ADVERTISEMENT

Table Locks In Exclusive Mode

Jan 6, 2011

Under what scenarios do we lock a table in the exclusive mode.

View 1 Replies View Related

Updating Table In Session - Shared Versus Exclusive Lock

Jan 28, 2013

I have a question. If we have two scott sessions. I am updating a table EMP in session

1. It means it is exclusively locked.It cannot be used by session 2. Then can we use select command on table EMP in session

2.? This command should not work according to me. But it is working.

View 14 Replies View Related

EXCLUSIVE Value Depreciated?

Aug 16, 2013

I read that the value EXCLUSIVE (REMOTE_LOGIN_PASSWORDFILE parameter) is supported for backward compatibility. It now has the same behavior as the value SHARED.So is the EXCLUSIVE value deprecated? Oracle Database Reference doesn't mention that.

View 6 Replies View Related

Unexplainable Exclusive Transaction Locks?

Aug 23, 2010

I have a job which runs the procedure below concurrently in 4 different sessions; It updates two tables.

PROCEDURE UPDATE_TAB_1_AND_TAB_2( traceIdTab IN pl_sql table,
individualIdTab IN pl_sql table,
fileSeqIdTab IN pl_sql table,

[Code].....

Each session is passed a sequence generated file ID; so the records processed in each session are completely different.

However, everytime this job runs, without failure, ONLY TWO sessions process concurrently, while the other two sessions are blocked. Once the first two have finished, then the remaining two sessions start work.

I have being monitoring the sessions on each run daily, and realized that the first two sessions processing are each holding a transaction exclusive lock on objects; hence blocking the other two sessions.

When I tried to find the objects that the two running sessions have a lock on, I cant seem to find anything by searching DBA_OBJECTS.object_id. However, when I look for the objects that are being waited on, its either a partitioned table or a partitioned index on either table_1 or table_2.

At first, I thought it was an ITL lock and after much analysis, I did not find anything which definitely pointed to an ITL lock. However, just to make sure, I increased the INITTRANS value from 2 to 5, but the problem did not go away.

At this point, I have applied all I know to understand the origin of the TX lock and how I can work around this situation, and decided to ask higher powers in Oracle for advise.

View 4 Replies View Related

SQL & PL/SQL :: Exclusive Lock On Tables - Run Job By Scheduling

Sep 27, 2011

@ the end of the day means After date changes i need to populate the new row in Some of my tables with the previous date values with the new date.. In that time some other Transaction will Occur on those tables so we need to lock all the tables in that time..Even i tried by doing the Exclusive lock on the tables...

execute immediate 'LOCK TABLE CTR_SALES IN EXCLUSIVE MODE NOWAIT';
execute immediate 'LOCK TABLE CTR_STK_ASSIGN IN EXCLUSIVE MODE NOWAIT';

And how to run this function @ 12:00 in the midnight by scheduling.... And 1 more thing how to pick the recent (Transaction) row on that table. I tried from the rowid it's not working

View 1 Replies View Related

Security :: Set Exclusive To Remote Login Password?

Nov 28, 2011

i create password file in oracle 10g now i want to Set the EXCLUSIVE to REMOTE_LOGIN_PASSWORD initialization parameter. so what should i do.

View 5 Replies View Related

Backup & Recovery :: ORA-19573 - Cannot Obtain Exclusive Enqueue For Datafile 1?

Nov 6, 2012

i backup my database using rman into my external disk using this command

RMAN> run
2> {
3> backup database format 'H:ackupkp_%u' tag='sh';
4> backup archivelog ALL format 'H:ackuparc_%u' Delete input;
5> }

Starting backup at 06-NOV-12
using channel ORA_DISK_1
channel ORA_DISK_1: starting full datafile backupset
channel ORA_DISK_1: specifying datafile(s) in backupset
input datafile fno=00001 name=F:ORACLEPRODUCT10.2.0ORADATAORCLSYSTEM01.DBF

[code]...

View 5 Replies View Related

Data Guard :: ORA-01102 / Cannot Mount Database In EXCLUSIVE Mode

Apr 28, 2003

How i create Standby Database in Same HOST, we using SUN OS 5.8.

I read form Oracle DOC that i can create Standby Database in Same HOST and follow the tutorial , but when i try to mount standby database using ALTER DATABASE MOUNT STANDBY DATABASE EXCLUSIVE; i got a error message ORA-01102: cannot mount database in EXCLUSIVE mode

View 6 Replies View Related

Server Administration :: ORA-01102 Cannot Mount Database In Exclusive Mode

May 10, 2002

I performed Shutdown Immediate in Oracle 8I and now I am unable to mount the database.I'm getting the following message: ORA-01102 Cannot mount database in Exclusive mode/I only have one database running on this machine. It was automatically created by Oracle installer upon installation of Oracle software. I can no longer connect via SQL * Plus,Only through Server Manager (connect internal)

View 8 Replies View Related

Data Guard :: Oracle 9i - Cannot Mount Database In EXCLUSIVE Mode

Jun 30, 2008

I'm trying to create a physical standby database on my Oracle9i DB runing on WinXP.

Note: I have both Primary and Standby on the same system.

Actually everything went well .... I did created the standby DB but the problem is I can not start my primary DB if my standby DB is mounted. I get this error:

ORA-01102: cannot mount database in EXCLUSIVE mode

And when I read about the error message I learnt that I should start my DB in compatible mode ...

View 5 Replies View Related

Reports & Discoverer :: Value In Table Column Based On Some Existing Column Value Automatically Without User Intervention

May 15, 2011

i have two questions.

(1) how can i fill some value in a table column based on some existing column value automatically without user intervention. my actual problem is i have 'expiry date' column and 'status'. the 'status' column should get filled automatically based on the current system date. ex: if expiry date is '25-Apr-2011' and current date is '14-May-2011', then status should be filled as 'EXPIRED'

(2)hOw can i build 'select' query in a report (report 6i) so that it will show me list of items 'EXPIRED' or 'NOT EXPIRED' or both expired and not expired separately in a single report based on user choice. 'EXPIRED' & 'NOT EXPIRED' can be taken from the above question no. 1.

View 3 Replies View Related

Performance Tuning :: Update Currency Column Of One Table Using Other Table Currency Column?

May 11, 2012

I am trying to update currency column of one table using the currency column of other table using the following sql code.

update ODS.SO_ITEM OSI
set CURRENCY__CODE=(select currency__code from sa_sales.SO_ITEM SSI where SSI.ID=OSI.ID)

This update is taking taking a lot of time and is never ending.

should i create index on source table (SA_SALES.SO_ITEM) or on target table (ODS.SO_ITEM) ?

View 7 Replies View Related

SQL & PL/SQL :: Add New Column To Table Between Column List?

Jun 16, 2010

How to add column 'col_new' in below table after the column 'col1'?

Table name: ofq1
table structure.
columnname datatype
------- -------
COL1VARCHAR2(20 BYTE)
COL2NUMBER
COL3DATE
COL4DATE

View 8 Replies View Related

All Columns Of A Table Are Part Of Primary Key Column Of That Table?

Feb 22, 2011

if a table contains two columns and both are part of the primary key of that table (Kind of obvoius).

should i opt for a index organized tbale in this case ?Or should i opt for another running sequential colum which would serve as a primary key of this table and define the actual two columns of the system as unique keys.

there is a drawback if a most of the tables of a database contain composite primary keys?

View 3 Replies View Related

SQL & PL/SQL :: How To Join A Table Column Names With Data From Other Table

Jul 18, 2012

I am trying to join column names from a table with data from a different table. I think i should be able to pass the parameter to a 'select list' in a query. Look at my sample data below. And the data in sales table can grow till 15 rows and similarly corresponding columns in saleshist.

CREATE TABLE SALESHIST
(
PRODUCT VARCHAR2(30 BYTE),
Q1 VARCHAR2(30),
Q2 VARCHAR2(30),
Q3 VARCHAR2(30),
Q4 VARCHAR2(30)
)
[code]......

View 6 Replies View Related

PL/SQL :: How To Get Column And Table Name By Given Column Value

Sep 28, 2012

I have a requirement as to find all the tables and columns containing keyword "SELECT" in my database. I followed forum

Re: How to find the column name and table name with a value

But when i run the below query on 11.0.2g Oracle Database

select table_name,
column_name,
:search_string search_string,
result
from (select column_name,

[Code]...

I get

ORA-29913: error in executing contains callout ORA-20000: Oracle Text error: 29913. 00000 - "error in executing %s callout"

*Cause:    The execution of the specified callout caused an error.
*Action:   Examine the error messages take appropriate action.

View 5 Replies View Related

SQL & PL/SQL :: Use Value Of One Column In Other In Same Table

Aug 17, 2011

I have two table country and state.Columns are given below

SQL> DESC Country

Name Null? Type
----------------- -------- --------------
PRIMARY_KEY NOT NULL NUMBER
DISPLAY_ORDER NOT NULL NUMBER
NAME NOT NULL VARCHAR2(50)
TREE_POSITION NOT NULL VARCHAR2(250)
PARENT_ID NUMBER

SQL> desc state
Name Null? Type
----------------- -------- -------------------------
PRIMARY_KEY NOT NULL NUMBER
DISPLAY_ORDER NOT NULL NUMBER
NAME NOT NULL VARCHAR2(50 CHAR)
VALUE NOT NULL VARCHAR2(50 CHAR)
TREE_POSITION NOT NULL VARCHAR2(250 CHAR)
PARENT_ID NUMBER

Now I have to insert the values in the state table taking from the country table.

EXAMPLE :

INSERT INTO STATE (PRIMARY_KEY, DISPLAY_ORDER, NAME, VALUE, PARENT_ID, TREE_POSITION) VALUES (251, 1, 'Alaska', 'AK', 233, 'STAT_USUS_AKAK');

but here the tree position is static it can be anything at the client side so I want to make it dynamic. So to make dynamic what I have used is mentioned below:

INSERT INTO STATE
(PRIMARY_KEY,DISPLAY_ORDER,NAME, VALUE,
PARENT_ID,
TREE_POSITION)
VALUES

[code].....

Now I want that Quote: select tree_position from L_STATE_ITEM where name ='United States')||'_ALAL' which i have used in the state table to put value in the tree_position, I want to make the other half part after the concatenation operator "_ALAL" also dynamic.

So I was just wondering If I can pic that value from the "VALUE COLUMN" of the same table.

View 3 Replies View Related

How To Add New Column At Specified Location In A Table

Dec 29, 2010

How can I add new column at the specified location in a oracle table? I am having a flat file from which data is inserted to the table..But initially I don't need that column so I m not having this column in the table but if further i need that column at the particular location then how can I do this..?

View 1 Replies View Related

Update New Column Within Same Table

Oct 22, 2010

I have a table ITEM as under;

ARTICLE VRTCODENAMESTATUSNEW_NAME
4KABAN.NM.12.21121143SU19I
4KABAN.NM.12.21564101SU23I
4KABAN.NM.24,5.22491015SR08I
4KABAN.NM.24,5.23181038SR22I
4KABAN.NM.24,5.23491015SR08I
4KABAN.NM.24,5.24121161SR26I

how to update the filed from NAME to NEW_NAME, I need following output.

ARTICLE VRTCODENAMESTATUSNEW_NAME
4KABAN.NM.12.21121143SU19ISU19
4KABAN.NM.12.21564101SU23ISU23
4KABAN.NM.24,5.22491015SR08ISR08
4KABAN.NM.24,5.23181038SR22ISR22
4KABAN.NM.24,5.23491015SR08ISR08
4KABAN.NM.24,5.24121161SR26ISR26

View 2 Replies View Related

Using Column Data As Table Name?

Nov 5, 2012

I have some tables. TABLE1 contains columns called query_id and a column called List_name TABLE2 holds a list of data and the TABLE_NAME = value in TABLE1 held under LIST_NAME TABLE3 contains column with Query_ID and other info.

Is it possible to grab the entry in TABLE1 under LIST_NAME as a TABLE_NAME in a data source?

View 1 Replies View Related

Get Values From Table Column Using PL/SQL Or Just Using SQL

Dec 3, 2008

I'm having a table which has a column which has values given inside square brackets.

[[[123412]]] ,[[[[werer34]]]],'[[qw2_w3rt]]

Now, the requirement is to get the values which are inside the innermost square brackets.Such as in

First case : 123412
Second one: werer34
Third : qw2_w3rt

Only the values inside are needed. Is there any way to achieve it using Pl-Sql or just using Sql ?

View 3 Replies View Related

Add A Column To Dual Table

May 17, 2012

i'v a problem regarding dual table,i logged to oracle as sys as sysdba and i add a column to dual table and then want to delete that added column but oracle gives "ORA-12988: cannot drop column from table owned by SYS"

i'm not able to drop any user oracle gives "ORA-00604: error occurred at recursive SQL level 1" "ORA-01031: insufficient privileges"

another error:: SP2-0575: Use of Oracle SQL feature not in SQL92 Entry Level oracle gives error when i want to switch user all problems starts when i add that column to dual table

View 1 Replies View Related

How To Select Table From Known Column Name

Sep 2, 2009

I want to find out all the tables that contains a known column name?

I know a column name called 'receiving_number', but don't what what table it's in.

View 2 Replies View Related

Dual Table Has Only One Column?

Oct 29, 2010

why the dual table has only column?

View 3 Replies View Related

SQL & PL/SQL :: Set Default Value For A Column Of Table

Aug 30, 2010

How to set default value of particular column of a table ?

View 5 Replies View Related

SQL & PL/SQL :: How To Find Table That Contains Certain Column

Nov 9, 2011

To find out column in which table it is located.

View 1 Replies View Related

SQL & PL/SQL :: Query For Table Has 90 Column?

Jul 22, 2010

I have one table which has 90 columns all has varchar2 datatype except one Column[primary key (Number)]. In this Table we have 1000 records, I want to fetch those records from Table which has value in all 90 columns means there is no null value in any column.

I know simple method Like this :-

column_name1 IS NOT NULL AND Column_name2 IS NOT NULL.

Like this we can write IS NOT NULL condition for all column.Is there any other way to write this Query because it makes Query very longer and it is very tedious job to write this Condition for all Columns.

View 3 Replies View Related

SQL & PL/SQL :: How Many Column Can Be In Table (9i Version)

Apr 8, 2011

How many column can be in a table (9i Version)?

View 1 Replies View Related

SQL & PL/SQL :: How To Find Table And Column Name

May 14, 2013

With Data in a table, is it possible to find out the table name and column name? Means i know the account number (data) of the table and with this data i want to find out column name and table name.

View 3 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved