View using db link

I have 3 databases with identical table structure installed in 3 different servers.(East ,West & South) To view consumers bill information
from any database I am using view with db link.
v_bill_CASH_data is base view created in every datbase
In east database my script for view creation is
create or replace view v_atp_bill_data as
select *
from v_bill_CASH_data
union
select *
from v_bill_CASH_data@westg
union
select *
from v_bill_CASH_data@southg;
where westg and southg are db links to connect to database of west and south.
The problem is when any one of the machine is not up I am not able to view consumer's data in other two database.
Should I change the script of view v_atp_bill_data or other way around?

You should go in various directions
a) make sure all databases are up 7 x 24, do not run this code during scheduled maintenance of any of the databases.
b) Included proper error trapping
c) consider consolidating three databases into one, adding an extra column, partioning on that column
d) consider using Advanced Replication, Streams or Change Data Capture, or whatever applies to your version to make sure all data is available everywhere,
when c) isn't possible.
All other 'solutions' are doomed to failure,
Sybrand Bakker
Senior Oracle DBA

Similar Messages

  • M View Using DB Link ??

    Dear Guru's,
    DB_VERSION=10.2.0.4
    OS_VERSION=Windows 2008 R2
    RAM_SIZE=32 GB
    We have 2 production (OLTP) database( DB1 (18GB) and DB2 (200GB) ) on a server out of which DB2 database has almost 20 Materalized Views all (REFRESH FORCE ..ON DEMAND).
    I have already informed the client that this is not the OLAP database where you are going to make use of the M Views for reporting purpose.
    However currently the client does not have any alternative.
    Breif details :-
    Out of 20 M Views 3 refresh once a week and where as the rest refresh every night daily.
    We are currently testing a new website for which we had to re-schedule all M Views from their Old timings to New Timings i.e. Daily Basis.
    But post re-scheduling the database performance was badly degarded as the database was too slow also the number of archives increasted to 300GB which was earlier 100 GB.
    To resolve the issue , we had to go back to the old timings and the database is currently working fine.
    Requirement :-Client is looking out for an alternative solution as he needs to once again change the M View refresh time i.e. Daily Refresh.
    We already have 2 Oracle Instance on the server
    Questions :-
    1. Can i create another database ( sayTESTDB2 ) in no archivelog mode and create a db link to reduce the load on the server ?
    2. If Yes .. Then is there any relavent link /example or Metalink Note ID for the same??
    3. What all parameters do i need to consider while creating a DB Link ?
    3. Out of 32 GB RAM , I have given 4GB and 8GB sga_max to DB1 and DB2 Respectively . Also the cpu utilization is normally 50-%60%.
    Since currently we do not have any Licence for other server ..
    Can i make use of the same server ( i.e. creating 3 rd Oracle Instance )Will it be a good idea ?
    Since the main intention of this activity is reduce the load from the DB2 onto TESTDB when the daily refresh has set once again.
    Appreciate your suggetion.

    Thanks every one.. I have made it finally ..
    Here is the requirement :-
    10G (UAT Database) Table where we need to create MViews using DB Link
    PROD(Target database)- Has TGT_OWNER schema under which all 20 MViews are present.
    1.Added tnsentry of target database i.e. PROD onto the 10G(UAT) Server :
    tnsentry:
    PROD =
      (DESCRIPTION =
        (ADDRESS = (PROTOCOL = TCP)(HOST = X.X.X.X)(PORT = 1528))
        (CONNECT_DATA =
          (SERVER = DEDICATED)
          (SERVICE_NAME = PROD)
      )2. In 10G(UAT DB), Created a test tablespace GIRISH
    3. In 10G(UAT DB), Created GIRISH user with GIRISH default tablespace
    4. Given CONNECT,RESOURCE,CREATE ANY MATERIALIZED VIEW grants to GIRISH user
    5. connected to girish/pwd
    10G>show user
    "GIRISH"
    6. created db link
    10G >create database link "PROD.ORACLE.COM"
    2  connect to TGT_OWNER
    3  identified by <pwd_of_tgt_owner>
    4  using 'PROD';
    database link created.7. Verfied if the db link is working fine by query one of the TGT_OWNER table present in the target database:
    10G >SELECT COUNT(1) FROM [email protected];
    COUNT(1)
      13848. Editied the M View script copied from the toad.
    Where i have changed the OWNER_NAME,TABLESPACE NAME,Added DB Link in from clause of the target database
    10G> Show user
    "GIRISH"
    10G>CREATE MATERIALIZED VIEW GIRISH.MVIEW_TEST
         PCTFREE 10 PCTUSED 0 INITRANS 2 MAXTRANS 255
         STORAGE(
              INITIAL 64 K
              MINEXTENTS 1
              MAXEXTENTS UNLIMITED
              PCTINCREASE 0
              BUFFER_POOL DEFAULT
    TABLESPACE GIRISH
    LOGGING
    NOCACHE
    NOPARALLEL
    USING INDEX      PCTFREE 10 INITRANS 2 MAXTRANS 255
         STORAGE(
              BUFFER_POOL DEFAULT
    REFRESH FORCE
         ON DEMAND
         START WITH TO_DATE('14-Jul-2012 01:00:00','dd-mon-yyyy hh24:mi:ss')
         NEXT sysdate + 1
         WITH ROWID
    USING DEFAULT LOCAL ROLLBACK SEGMENT
    DISABLE QUERY REWRITE AS
    select distinct a.invfname Customer_Name,b.foliono FolioNo,c.short_name Scheme,b.amount Amount,b.brokcode Broker_Code,b.dateexec Sip_Due_Date from
    [email protected] a, [email protected] b,[email protected] c
    where a.foliono=b.foliono
    and b.schcode=c.sch_code
    and dateexec between sysdate and sysdate+30
    and ceasedt is null;
    Materialized view created.Thanks once again ..It was a wonderful learning with Oracle :-)
    Good Day !!!!
    :-)

  • Insufficient priv error when creating a materialised view using DB link!!!!

    Hi,
    I have a two databases db1 and db2.
    I have created a database link from db2 to access user1 schema in db1.
    When i try to create a materialised view by accessing user1 table using user 'user2' in db2 database, i get error "ORA-1031: Insufficient Privilege".
    The user2 has the priviliges "create view", "create any view", "create materialised view" etc.
    I am able to select data, of the table using the database link, but creating materialised view gives this error.
    I want to know if the user "user1" should be granting any privilige to user2, if so how is it possible as user2 dosent exist in db1!
    i.e should i give command something like "grant select on user1.table to user2@db2"(this dosent work as it says user2@db2 dosent exist, obviously as its taking user2@db2 as a username in db1 schema)
    or is this a problem with user2 priviliges in db2 database, if so what are all the priviliges that have to be given to user2 in db2 schema.
    regards,

    Hi,
    User from db1 can not assign any privs to user on db2 database. If user from db1 want to access any object from db2 database, then on local level user2 on db2 should have all the acess to required object. Then you can use user2 on db2 using dblink from db1 user to access those objects residing on remote database.
    If user1 from db1 can grant privs to user2 on db2 database on any objects on db2 database then it is highly security issue. This is not permitted.
    Regards
    e.g.
    conn userx@db2
    grant select on userx.table1 to user2;
    conn user2@db2
    select count(*) from userx.table1;
    conn user1@db1
    select count(*) from userx.table1@db2_dblink;
    Edited by: skvaish1 on Apr 29, 2010 3:57 PM

  • How to add SharePoint 2013 Promoted link list view web part in page programatically with Tiles view using CSOM.

    How to add SharePoint 2013 Promoted link list view web part in page programatically with Tiles view using CSOM. I found that it can be
    done by using XsltListViewWebPart class but how can I use this one by using shraepoint client api.
    shiv

    Nice, can you point me to the solution please ?
    I'm  trying to do this but I get an error : 
    Web Part Error: Cannot complete this action. Please try again. Correlation ID: blablabla
    StackTrace:    at Microsoft.SharePoint.SPViewCollection.EnsureViewSchema(Boolean fullBlownSchema, Boolean bNeedInitallViews)     at Microsoft.SharePoint.SPList.GetView(Guid viewGuid)   
    All help really appreciated.

  • When I click on a link in an RSS feed it used to indicate that I'd viewed that particular link by changing the icon to the left of the link. It doesn't do that anymore. [SOLVED]

    When I click on a link in an RSS feed it used to indicate that I'd viewed that particular link by changing the icon to the left of the link. It doesn't do that anymore. This started happening right around the time I updated to Firefox 4, but may have been a little before that too. For some things, like news and web comics it's just a little annoying. For important things like looking for new journal articles for my job, it literally makes my job more difficult. So fixing this would make my day.

    I seem to have solved my own problem. When I disabled the add-on "Tab Renamizer" everything started working fine.

  • How do I use mobile link to view documents on more than one device?

    I have documents on my iPhone and want to send them to my iPad using Mobile Link. How do I do this?

    Hi bephys,
    For this you can simply upload the doc to files.acrobat.com and send the link to the recipient via Adobe Send.
    Anyone having the link would be able to access the doc.
    Alternatives would be Google Drive or One Drive.
    These links might be helpful to you:
    https://support.google.com/drive/answer/2498081?hl=en
    http://windows.microsoft.com/en-in/onedrive/ios-faq
    Regards,
    Rave

  • Using a view as left link

    Hi All
             I want to develop a left link which will appear in every view of the application and will have the links by clicking which right view can be changed like our e-mail sites where we click on folder name and right part gets changed.
             For this functionality I have created a view for left link and added it to a view set so that i don't need to add all those links to each and every view again and again but i have a problem like when i click on the link how to change the lift link from one view to another.
    e.g.
    i have links called inbox and  spam in left link and currently showing inbox in right view now when i click on spam automatically right view should be get changed to spam folder.
    how can i achieve this functionality. Is it possible through view set or if any other way to implement this?
    Thanks in advance
    Prasanna

    Hi Prasanna,
    Create a Viewset having two regions left and right.
    In left view have all the link and attach some actions to them.
    Like
    navigateToInbox()
    navigateToSpan()
    In the actions simply fire an outbound plug to corresponding view that is embeded in right side of viewset.
    On firing of view corresponding view will be displayed in the right region.
    Regards,
    Ashwani

  • Logical error in creating tables using db link in solaris

    Hi,
    While creating table using the syntax create table newtab...as select * from tab@dblink .. I am facing a problem. The newtab table created is having a structure different (from datalength point of view of varchar2 and char datatypes) from the source. The data length is getting tripled i.e. if a column a is varchar2(20) in tab then it is becoming --- a varchar2(60) in newtab. This is happening in solaris environment when the two databases are in 2 different servers. Please let me know if there are any patches to resolve the problem.
    Thanks
    Arnab

    ORA-02019: connection description for remote database not foundHave you used this database link successfully for some other queries?
    The error posted seems to indicate that the DB Link is not functional at all. Has it worked for any other type of DML operation or is this the first time you ever tried to use the link?

  • Is there a way I can view/manage devices linked to my iCloud account?

    Is there a way I can view/manage devices linked to my iCloud account? I know how to view the devices linked to my iTunes account, but I am not sure if this is possible to see with an iCloud account.

    You can't, except by seeing if they are using services associated with the account.  You could, for example, launch Find My iPhone on iCloud.com to see what devices appear (which obviously wouldn't show devices not using Find My iPhone).  Similarly, you could go to Settings>iCloud>Storage & Backup>Manage Storage to see what devices appear on the Backups list (which won't show devices not using iCloud backup).

  • How to open sharepoint files in edit mode using associated link?

    Hi All,
    We are trying to use the URL links available through SSM to open documents we hold on SharePoint. These will be the action plans for the risks we are entering as KPIs. The aim is to established a one-to-one link between the risk KPI and the risk action plan as this is a fundamental reason behind using SSM for Risk.
    However, when we enter the SharePoint URL into the SSM admin screen, clicking the link from SSM UI opens up the file as an internet explorer page which can not be edited and saved back to SharePoint. We did find a way to get through My Network Places to over write the file, but this only works if you have previously opened and edited and saved the file from SharePoint and requires lots of navigation by the user and is therefore not an appropriate solution.
    Is there any way we this can be achieve? Appreciate your replies. Thanks in advance.
    Regards,
    David

    Hi Bob,
    Thanks for your reply. What I meant was when we put the UNC into SSM as a link in the URL box, SSM does not use the address it is given, instead it adds a http:// back in front and once again fails when opening the file in sharepoint.
    For example:
    SharePoint folder view used in test:
    http://wccportal/resources/performance/risk/Risk%20Action%20Plans/Forms/AllItems.aspx?RootFolder=%2fresources%2fperformance%2frisk%2fRisk%20Action%20Plans%2fDOR&FolderCTID=&View=%7b84123F22%2d74F2%2d41B9%2d918C%2dFF23DAE35EB3%7d
    Excel UNC link to folder
    wccportal\resources\performance\risk\riskactionplans\DOR
    SSM UNC Link - SSM changes the address to include http:// and also removes other \ breaks and adds in numbers and symbols.
    Is there a way to stop SSM converting the local address back into a web address?
    Thanks,
    David

  • Creating a document & making it accessable on the web using a link.

    There is an issue I want to address to the forum. I don't want to clutter up my posted topic with an entire page of information that is rellevent to my topic. How can I create a document that other Apple Discussion members can view it using a link? Where can I "put" it so that it's accessible?
    iMac G4 (snowcone)   Mac OS X (10.4.7)  

    Most any ISP you have will give you storage space, then it's easiest to ftp it to your storage, then post the URL like this...
    http://web3.ehost-services.com/bdaqua/
    I use TransmitX, but other free ftp APPs exist like Cyberduck. If you vist your ISP's site it should tell you jow to do it... if not post back with your ISP and I'll help further!

  • SWF Loader using OpenDoc links

    I am having no luck using an opendoc link inside the SWF loader. Any suggestions?
    Is my other choice to load the swf from a network location? I am able to load successfully that way (even run the data connections)
    I've tried different variations of this link and all I get is the 100% screen, with no dashboard -
    -SERVER-//OpenDocument/opendoc/openDocument.jsp?&iDocID=ARmopxdsSohMvuPJL67dARE&sIDType=CUID&sType=Flash
    Xcelsius SP3, trying to load other xcelsius swf files already in infoview.
    Thank you

    Hi,
    I tried using the links provided
    It gives me the below exception:
    message
    description The server encountered an internal error () that prevented it from fulfilling this request.
    exception
    java.lang.NullPointerException
    com.businessobjects.clientaction.xcelsius.DocumentDownload.getSWFbyName(DocumentDownload.java:110)
    com.businessobjects.clientaction.xcelsius.DocumentDownload.service(DocumentDownload.java:149)
    javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    Is there any modification required on the server side to run the DocumentDownload syntax.
    I am able to view the swf using the opendoc syntax.
    Help is appreciated.
    Have breaking my head and reading so many forums and post for weeks. banghead.gif
    Link which is working using opendoc:
    https://ServerName/OpenDocument/opendoc/openDocument.jsp?sDocName=TestFile&sKind=Flash&iDocID=144902
    Please help me with the link for using Documentdownload
    Documentdownload link - not working:
    https://ServerName/OpenDocument/opendoc/&sPath=[My Favorites]&downloadDocument?iDocID=XXXX&sKind= Flash
    Also please let me know if documentdownload link would take me to the login page if the CELOGONTOKEN is not appended.
    Note: I am able to get the CELOGONTOKEN successfull

  • Session using db link?

    Some of the Users are connecting to my database through database links.
    How to know the user session is using db link?
    Is there any view, which shows connected dblink's ?

    Even v$session would show this, but indirectly.
    Whenever any query is given through a dblink, it automatically starts a transaction, so connecting this with v$transaction with username, you can find the transaction and from there get through v$sqlarea or v$sql to find the sql with dblink. Though its a round about way, it is possible to find session using dblinks, thats is my point. pls try it and let us know.
    Siva

  • Creating user using database link

    Hi
    I have 11g installed on one of the server
    I have created the database link BUGAU to bugau.us.oracle.com
    link works fine
    select * from table@"Bugau" gives the expected result
    I need run the below statement from my server using the dblink.but not sure how to use the dblink for this purpose.Please assit
    CREATE USER ABC IDENTIFIED BY welcome DEFAULT TABLESPACE USERS_001 TEMPORARY TABLESPACE temp123;
    GRANT DEFAULT TO abc;
    ALTER USER abc PROFILE LEVEL_1;
    Thanks
    Archana

    as mentioned in oracle documentation for db link purpose: you can use it for accessing schema objects in remote database..
    http://download.oracle.com/docs/cd/B28359_01/server.111/b28286/statements_5005.htm
    >
    Use the CREATE DATABASE LINK statement to create a database link. A database link is a schema object in one database that enables you to access objects on another database. The other database need not be an Oracle Database system. However, to access non-Oracle systems you must use Oracle Heterogeneous Services.
    After you have created a database link, you can use it in SQL statements to refer to tables and views on the other database by appending @dblink to the table or view name. You can query a table or view on the other database with the SELECT statement. You can also access remote tables and views using any INSERT, UPDATE, DELETE, or LOCK TABLE statement.
    >
    For creating users, you have to login to the remote database itself, You also need to login using the user who has the necessary credentials to create the user.
    Regards,
    Dipali.

  • How to create links and how to use that links to go to other pages?

    my question is....how to create links...i mean by using make link option.....when we do right click on a word,etc in the design view.....and my other question is.....how to use that links to go to other pages.....i mean when i click on a link...it takes me to another web page.....

    Please do not post the same subject to more than one forum.

Maybe you are looking for

  • Memory on 4g

    I have a 4gig nano and erased all the songs on it to refresh everything, when i did this it shows the memory as 1.5 g and i can not get rid of it, down to no memory with no songs and no photos. Anyone had this problem in the past, and how do i fix it

  • Deploying a WAR file containing .jsp and servlets (also uses JNI)

    Deploying a WAR file containing .jsp and servlets (also uses JNI) on Windows 2000 We had problems making it initially work on Sun ONE Web Server 6.0 Service Pack 1 because of lack of good iPlanet Web Server documentation on deploying such files. This

  • I installed the latest update of itunes and now I can't even open itunes. I have Windows 7.

    As seen above. I installed the latest update of itunes, as an admin on my windows 7 and now nothing is working. I already deinstalled itunes. But nothing is working. Could please someone help. It's the 11.1 or 11.2 update I think

  • I have changed PC's and want to use my Illustrator License from my old machine on my new one

    I recently went from using a lap top with little storage to a desk top with lots of storage so I can better use my Illustrator and photoshop programs. I would like to move my license and my access to the cloud from my old PC to the new one is that po

  • Output type configuration

    Hi, I have one doubt. What is the difference between configuring the output type through nace and spro. For few transactions, i see that the functional team add the custom driver program or the form name through NACE and for some cases through SPRO.