Creating cdc table in a different database

this is my code which creates cdc table.
how do i create my cdc table in a different db and not in the db where my source is residing.<i think i need to use db link but where do i specify it??>
SQL> exec dbms_logmnr_cdc_publish.create_change_table(owner => 'dvd', -
change_table_name => 'classes_ct', -
change_set_name => 'SYNC_SET', -
SOURCE_SCHEMA => 'dvd', -
SOURCE_TABLE => 'classes', -
COLUMN_TYPE_LIST => 'class_id NUMBER, -
class_title VARCHAR2(30), -
class_instructor VARCHAR2(30), -
class_term_code VARCHAR2(6), -
class_credits NUMBER', -
CAPTURE_VALUES => 'both', -
RS_ID => 'y', -
ROW_ID => 'n', -
USER_ID => 'n', -
TIMESTAMP => 'y', -
OBJECT_ID => 'n', -
SOURCE_COLMAP => 'y', -
TARGET_COLMAP => 'n',-
OPTIONS_STRING => null);PL/SQL procedure successfully completed.

Still fails.  Here is table definition in new database, confirmed identical with original database:
CREATE TABLE [dbo].[Networks](
        [ID] [binary](5) NOT NULL,
        [Description] [varchar](255) NULL,
        [Network] [binary](4) NOT NULL,
        [Netmask] [binary](4) NOT NULL,
        [Parent] [binary](5) NULL,
        [RowID] [uniqueidentifier] ROWGUIDCOL  NOT NULL,
        [RowVersion] [timestamp] NOT NULL,
 CONSTRAINT [PK_Networks] PRIMARY KEY CLUSTERED
        [RowID] ASC
)WITH (PAD_INDEX  = OFF,
       STATISTICS_NORECOMPUTE  = OFF,
       IGNORE_DUP_KEY = OFF,
       ALLOW_ROW_LOCKS  = ON,
       ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY],
 CONSTRAINT [IX_Networks] UNIQUE NONCLUSTERED
        [ID] ASC
)WITH (PAD_INDEX  = OFF,
       STATISTICS_NORECOMPUTE  = OFF,
       IGNORE_DUP_KEY = OFF,
       ALLOW_ROW_LOCKS  = ON,
       ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY]
I also created an Execute SQL Task which specifically did not include either the RowID or RowVersion columns, and it STILL dies with exactly the same error.
I'm stumped by this behavior - this makes no sense whatsoever.

Similar Messages

  • Synch Between Tables in Two different Databases

    Synch between Two Tables in two different Databases.
    I have two identical tables, table T1 in Database D1 and table T1 in Database D2. User can insert/update/delete/select from both of these tables in respective databases. Being said that how can keep them in Synch? Any thing added/modified/deleted should reflect in other. We like this to be Real-Time.
    We are thinking of creating a cross (two way) DB link between them and then update/insert/delete both the tables when changing one. Any suggestions?
    Thanks

    One of my colleagues used snapshot in their previous projects, but he told me that the performance of it wind down while the records in tables increase. I have no idea about the exact situation, but I'm believing we'd think twice about it.
    eilison
    [email protected]

  • How to create a table in Oracle Lite database?

    Hi,
    I have installed SOA 10.1.3 on my laptop. Now I am trying to create a table in the database to do some own examples. I have problem in installing oracle database. So I am trying to create a table in Oracle Lite database which comes with SOA suite. I am not able to do it, can some body suggest me please?
    Regards
    Khaleel

    HI James,
    Thank you so much. I am able to create table and insert rows and able to select them too. However I am not able to use these tables in my BPEL process for my practice. The DB adapter is throwing some error, any idea?
    --khaleel                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Creating new tables in Logical Standby database

    Hi
    I have a requirement to create new tables in logical standby database. These tables will not be present on primary database. Is it possible to do this ?
    I have a new schema already created which has the privilege to CREATE new table.
    I have stopped the logical standby apply.
    When I am now trying to create a new table but it is failing with error : insufficient privileges.
    When I am trying to run below statement on new schema it is also failing with error of insufficient privileges.
    alter session disable dataguard;
    Please help.

    user8819121 wrote:
    Thanks Mahir,
    I was able to create the table after logging in as sysdba.
    But I need my user on that table to execute DML statements. My user has privileges to insert,delete and update any table.
    I tried the following statements to disable the guard but it is sill not working
    ALTER DATABASE GUARD STANDBY.
    Do I need to skip the tables created using dbms_logstdby package to not making it part of SQL Apply ? I guess not since the table is not in primary database.
    Amit
    You can skip only on primary, your created schema on Standby is not in primary.
    Then you must change Status of data guard to NONE. NONE is means is not any security on your data.
    In Guard status NONE can change all schema data.
    Please check link: http://docs.oracle.com/cd/E11882_01/server.112/e10700/manage_ls.htm#CHDGFGHG
    Following tests on user created before guard status is change from ALL to STANDBY.
    C:\Users\Administrator>sqlplus / as sysdba
    SQL> conn test/test
    Connected.
    SQL> select table_name from user_tables;
    TABLE_NAME
    T
    SQL> insert into t values(22);
    insert into t values(22)
    ERROR at line 1:
    ORA-16224: Database Guard is enabled
    SQL> conn / as sysdba
    Connected.
    SQL> select guard_Status from  v$database;
    GUARD_S
    ALL
    SQL> alter  database guard standby;
    Database altered.
    SQL> conn test/test
    Connected.
    SQL> insert into t values(1);
    insert into t values(1)
    ERROR at line 1:
    ORA-16224: Database Guard is enabled
    SQL> conn / as sysdba
    Connected.
    SQL> select guard_Status from  v$database;
    GUARD_S
    STANDBY
    SQL> alter  database guard none;
    Database altered.
    SQL> select guard_Status from  v$database;
    GUARD_S
    NONE
    SQL> conn test/test
    Connected.
    SQL> insert into t values(1);
    1 row created.
    SQL> commit;
    Commit complete.And Now I want share with you new tests :)
    Now user creating when after guard status change
    SQL> drop  user test cascade;
    User dropped.
    SQL> select guard_status from v$database;
    GUARD_S
    STANDBY
    SQL> create user test identified by test;
    User created.
    SQL> grant create session,  resource, create table to test;
    Grant succeeded.
    SQL> conn test/test
    Connected.
    SQL> create table t (n number);
    Table created.
    SQL> insert into t values(1);
    1 row created.
    SQL> commit;
    Commit complete.
    SQL>It means when guard status is ALL then all of user created guarding.
    When you changed status to STANDBY then Logical Standby guard only primary schema and created schema before change.
    NONE is not guard any schema. it means you can delete standby schema data too.
    Regards
    Mahir M. Quluzade
    Edited by: Mahir M. Quluzade on Apr 19, 2013 4:07 PM

  • Creating Custom Tables in the Portal Database

    Is there a way to create custom tables in the portal database in EP6?
    Thanks,
    Melissa

    Thanks for responding, Nick.
    We want to be able to display informational messages on the logon page before the user logs in.  Currently we make changes to several ASP files in EP5 to display the messages.  We want to be able to give privileged users the ability to enter the message, enter start/end date, etc.  We want to do this in EP6 as well.

  • Create one tables from 2 different tables

    Hi,
    How I can create one table from 2 different tables. Source tables have data and I want to include it in new table.
    I try this:
    create table NEW_ONE
    select * from OLD_ONE
    union
    select * from OLD_ONE2;
    But it didn't work correctly :/

    I don't have any error. This syntax create table NEW_ONE, but this table have columns only from OLD_ONE table :/ There aren't any column from OLD_ONE2 :/ Any suggestions?
    I don't forget about "as" in my query, only in this post.
    Edited by: tutus on Sep 8, 2008 6:36 AM

  • Query to compare 2 different tables from 2 different database

    Is it possible to write a SQL query to compare 2 Tables from 2 different Oracle Database. Also I need a query to do the same when the database is same.
    Thanks in advance

    OK, well "compare" can mean one of two things: Compare structure or compare contents. Here is a quick script to compare column structures of two tables on one database:
    (select COLUMN_NAME,
    DATA_TYPE,
    DATA_LENGTH,
    DATA_PRECISION,
    DATA_SCALE,
    NULLABLE
    from dba_Tab_columns
    where owner=:OWNR1
    and table_name = :tablename
    minus
    select COLUMN_NAME,
    DATA_TYPE,
    DATA_LENGTH,
    DATA_PRECISION,
    DATA_SCALE,
    NULLABLE
    from dba_Tab_columns
    where owner=:ownr2
    and table_name = :tablename)
    union all
    (select COLUMN_NAME,
    DATA_TYPE,
    DATA_LENGTH,
    DATA_PRECISION,
    DATA_SCALE,
    NULLABLE
    from dba_Tab_columns
    where owner=:ownr2
    and table_name = :tablename
    minus
    select COLUMN_NAME,
    DATA_TYPE,
    DATA_LENGTH,
    DATA_PRECISION,
    DATA_SCALE,
    NULLABLE
    from dba_Tab_columns
    where owner=:ownr1
    and table_name = :tablename)
    If this query returns any rows, then these indicate that there are structural differences between the tables. We do a minus in both directions to ensure that an additional column in either schema will be returned in the query.
    If you are going across dblinks to remote tables then you have to amend the "dba_tab_columns" to "sys.dba_tab_columns@yourdblink"
    If you also want to compare indexes, triggers, etc then do the same sort of thing for the associated dba_ views for those objects.
    And if you want to compare table contents, then often the fastest way is also to check minuses in both directions, if the tables are not too big:
    e.g.
    (select * from schema1.table@dblink1
    minus
    select * from schema2.table@dblink2)
    union all
    (select * from schema2.table@dblink2
    minus
    select * from schema1.table@dblink1)
    local tables, of course, simply omit the "@dblink" issues.
    There are tools to help in such things. TOAD, for example, has a pretty good schema comparison tool, and there are plenty of other options out there. But if you need to script this yourself then the logic I've shown is a good starting point.
    Cheers,
    Mike

  • How to integrate different tables structures from different databases?

    Hi
    I'm new to oracle ..kindly help me with the below issue...
    I have same set of inter-related attributes (a,b,c,d) in two different databases A and B.
    The structure of tables in both the database are different but they carry same attributes in same relation.
    I have to integrate these attributes into single db object such that any update to base tables updates my object.How can i do this and what object will be helpful?
    Thanks

    Arun Rajesh wrote:
    Hi
    I'm new to oracle ..kindly help me with the below issue...
    I have same set of inter-related attributes (a,b,c,d) in two different databases A and B.
    The structure of tables in both the database are different but they carry same attributes in same relation.
    I have to integrate these attributes into single db object such that any update to base tables updates my object.How can i do this and what object will be helpful?
    ThanksWelcome to Forum!!!
    Please elaborate your question.
    Arun Rajesh wrote:
    I have same set of inter-related attributes (a,b,c,d) in two different databases A and B.1. What are the ATTRIBUTES?
    Arun Rajesh wrote:
    The structure of tables in both the database are different but they carry same attributes in same relation.2. Post the Table Structures.
    Arun Rajesh wrote:
    I have to integrate these attributes into single db object such that any update to base tables updates my object.How can i do this and what object will be helpful?3. What is the end result that you desire? A sample output shall help in our understanding.
    PS:- Please go through this to understand SQL and PL/SQL FAQ.
    Regards,
    P.

  • Query two tables in two different databases.

    Hello,
    I have to query two tables say 'a' in database "D1"and 'b' in database "D2".I am using sql developer and it is accepting only querying for repecting databases.
    i.e if i would like to access b from the sql script of D1 .Please guide me in this regard.
    thank you.

    Create a database link in DB "a" pointing to DB "b" then use the db link in your script.
    Message was edited by:
    skutz

  • Comparing Tables In Two Different Databases

    Hi,
    As part of our project, we need to perform table comparisons in two different databases. I am currently looking for various options to accomplish this.
    One of them is doing minus operation between these two tables.
    Also, i have looked at the data compare option in toad utility.
    Please suggest me any other options that makes my job easy.
    Thanks in advance,
    Sue

    Then just adapt the select that is there
    SELECT stid , c1, c2, c3                      
       FROM
      ( SELECT a.*,
             1 src1,
             to_number(null) src2        
       FROM  a   
       UNION ALL
       SELECT b.*,
             to_number(null) src1,
             2  src2        
        FROM b
       GROUP BY stid , c1, c2, c3
       HAVING count(src1)  count(src2)
       order by stid;Best regards
    Mohamed Houri

  • Joining tables from two different databases

    Hi,
    I am trying to join W_DAY_D from 1 database to another 2 database to the fact table . The datatype for CALENDER _DTis (DATE) from W_DAY_D  and the Create date from fact table is TIMESTAMP . I changed the the datatype in the phyiscal layer for CREATE DATE from the fact table to DATE and joined it with W_DAY_D (Calender_DT = create_date) Thought the rpd showed me no errors while saving it . But when I try adding the column in the report it throws me error
    State: HY000. Code: 10058. [NQODBC] [SQL_STATE: HY000] [nQSError: 10058] A general error has occurred. [nQSError: 43113] Message returned from OBIS. [nQSError: 43119] Query Failed: [nQSError: 46008] Internal error: File server\Utility\Server\DataType\SUKeyCompare.cpp, line 772. (HY000)

    I tried this ealier but it throws me an Invaild expression error. In the Physical Foreign key join
    "ABC"."test"."dbo"."W_DAY_D_Alias"."CALENDAR_DT" = CAST("CT"."EAST"."dbo"."Fact-TEST"."Input date " as DATE)

  • Tables from 2 different database schemas in 1 module

    I'd like to have only one module to store my source transactional tables.
    In my transactional system, I've got, differente database schemas.
    For example:
    I've got a schema, schema1 with a table called table1 and schema2 with table2.
    I've got a public synonym and granted the privileges to select table2 so, from schema1, I can see table2.
    I'd like to have only one MODULE to store my SOURCE transactional tables.
    But, when I create the module, I have to link it with a specific location, and a location is linked with a specific schema. When the list of objects to load is shown, I see the objects of the schema but no the others pointed with synonyms.
    Example: If I have a location linked to schema1 I only see table1, but don't see table2.
    IS THERE A WAY TO LOAD table1 and table2 IN THE SAME MODULE?
    thanks in advance!

    You cannot access objects in another schema via public synonyms.
    If your location is linked to schema 1, then in schema 1 create a private synonym to schema2.table2, grant read on table2 to schema1 from schema2, and then you will be able to see table2 to import it into OWB if you have the option to included objects referenced by synonyms checked.
    Cheers,
    Mike

  • When ever using table of an different database forms exits

    Hello
    i am using FORMS6i,oracle 8i
    i have two database A and B
    i have created a forms in A database which is accessing
    some table of database B.but when ever i open the form
    in form builder and try to compile it exits.So every time
    i have to create a local table in A which actually belong to
    database B to compile the form.is their any easy process
    to follow the above
    Regards

    It's definately worth applying a newer patch, say patch 17, then trying this again.
    You get them from metalink.
    Let us know what happens.

  • How to combine 2 the same tables from 2 different databases

    We have made 2 databases company1 and company2
    Both databases contains the same tables
    Now we want to make a report with server reporting services. The report must give us information from the 2 databases.
    We use the following query:
    SELECT     '501'as divisie, GRV_DebtorOutstanding2.[Debtor code] AS Debiteur, GRV_DebtorOutstanding2.cmp_name AS Naam, SUM(GRV_DebtorOutstanding2.[Outstanding Amount]) AS Saldo,
                          GRV_DebtorOutstanding2.blokkade, GRV_Debtors.City
    FROM         [501].dbo.GRV_DebtorOutstanding2 INNER JOIN
                          [501].dbo.GRV_Debtors ON GRV_DebtorOutstanding2.[Debtor code] = GRV_Debtors.[Debtor code]
    WHERE     (GRV_DebtorOutstanding2.blokkade = 'B')
    GROUP BY GRV_DebtorOutstanding2.[Debtor code], GRV_DebtorOutstanding2.cmp_name, GRV_DebtorOutstanding2.blokkade, GRV_Debtors.City
    ORDER BY Debiteur
    when we use the same query to select the data of the other database in the same query it doesn't work. I have tried it with the command Union All
    But it crashes,
    please help, to fix it

    Hi Robert,
    According to your description, you have created two same databases. When you run the same query for the second database, it doesn’t work.
    In your scenario, since databases are the same and the query for first database can work fine, it should also work when query the second database using the same query. When you create second dataset, please check if you have used a correct datasource
    which is second database. Then try to run the query again. If issue persists, please share the error message around the time when you query the second database.
    If you have any question, please feel free to ask.
    Best regards,
    Qiuyun Yu
    Qiuyun Yu
    TechNet Community Support

  • Can we create external table from an existing database table ?

    Hi everyone,
    As i understand, its possible to create a new table based on an existing table without copying any values from it, using the following command;
    CREATE TABLE newtable AS
    (SELECT * FROM oldtable WHERE 1=2);
    I would like to know whether we can do a similar thing with external tables. That is to create an external table with the same columns as of an existing table.
    Thanks in advance for your answers.

    You need to clear conception about external table.
    http://download.oracle.com/docs/cd/B19306_01/server.102/b14220/utility.htm#sthref1800
    http://download.oracle.com/docs/cd/B19306_01/server.102/b14231/tables.htm#sthref2448

Maybe you are looking for

  • Performance Problems on Faces Navigation Diagram and Hyperthreading query

    Am I the only one having performance problems when dealing with Faces-Config Diagrams of about 35 JSPs displayed on the sheet. using Jdev 10.1.3 It's taking my workstation about a full minute and a half to update the name of an arrow. The most stress

  • One time vendor invoice

    Hi Experts, I noticed that when I create invoice for one time vendor, the vendor data fields available is different with the normal vendor master data fields. Example : in normal vendor master data, there's field Street4. In the one time vendor maste

  • FF Mac Desktop Addon and links download errors after upgrade to 35.0.1

    My problem started when FF was repeatedly trying to automatically upgrade to 35.0.1. It repeatedly failed the incremental upgrade and said I should download from Mozilla.org. However, after doing that and installing 35.0.1 both addons and application

  • Mac os x lion crashes  all time

    I have  imac 12.1 core i5 20gb ram ddr 3 1333mhz 500gb hard disc work perfect i loved, but sometimes  panic for kernel task, mobile partner, or firefox especially when i work in protools mpowered 9 help me please i must format?

  • Bold, Emphasis formatting not displayed

    I have a report that I'm generating from cf (I bypassed the reportbuilder tool). The query pulls all the data from a sql db. The report properly inserts line breaks <BR>, however, whenever it encounters <em> or <i>, it will not format the text proper