Solved

How to get data from view for 2 orgs simultanously

Posted on 2013-01-09
2
558 Views
Last Modified: 2013-01-21
begin
fnd_client_info.set_org_context(1077);
end;

select * from oe_order_headers_v


now i want the data for org_id=104

any idea this is oracle applications question
0
Comment
Question by:pardeshirahul
2 Comments
 
LVL 76

Accepted Solution

by:
slightwv (䄆 Netminder) earned 500 total points
Comment Utility
I'm not an apps person so cannot say for sure if there is a better way to set multiple contexts but a purely database solution may be a global temporary table (GTT).

create a global temp table that mirrors oe_order_headers_v once:
create global temporary table gt_oe_order_headers_v
as select * from oe_order_headers_v where 1=2;

Then set each context and insert into the GTT then select from that?

exec fnd_client_info.set_org_context(1077);
insert into gt_oe_order_headers_v (select * from oe_order_headers_v);

exec fnd_client_info.set_org_context(104);
insert into gt_oe_order_headers_v (select * from oe_order_headers_v);

select * from gt_oe_order_headers_v;
0
 
LVL 6

Expert Comment

by:Javier Morales
Comment Utility
Please, may you clarify your question?

Many thanks in advance,
Javier
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Join & Write a Comment

Have you ever had to make fundamental changes to a table in Oracle, but haven't been able to get any downtime?  I'm talking things like: * Dropping columns * Shrinking allocated space * Removing chained blocks and restoring the PCTFREE * Re-or…
Configuring and using Oracle Database Gateway for ODBC Introduction First, a brief summary of what a Database Gateway is.  A Gateway is a set of driver agents and configurations that allow an Oracle database to communicate with other platforms…
This video explains what a user managed backup is and shows how to take one, providing a couple of simple example scripts.
This video shows how to copy an entire tablespace from one database to another database using Transportable Tablespace functionality.

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

7 Experts available now in Live!

Get 1:1 Help Now