Monday, November 29, 2010

Post 23 of series,Configure more complex goldengate replication with Tutorial

You are the Primal Being, the Most Wonderful Creator. There is no other as Great as You. Age after age, You are the One.
Forever and ever, You are the One. You never change, O Creator Lord. Everything happens according to Your Will. You
Yourself accomplish all that occurs. You Yourself created the entire universe, and having fashioned it, You Yourself shall
destroy it all.




Index of all the posts of Gurpartap Singh's Blog


Lets create more data for a little bit more complex replication.

In source in schema meditate create the following table.

create table place_at_time_of_death (
place_id number,
supercluster varchar2(30),
galaxy varchar2(30)
);



ALTER TABLE place_at_time_of_death
add CONSTRAINT place_id_pk PRIMARY KEY (place_id);



create sequence place_id_seq
increment by 1
start with 1
nomaxvalue
cache 20
;


alter table place_at_time_of_death add HUMAN_ID NUMBER;
alter table place_at_time_of_death add FIRSTNAME VARCHAR2(30);
alter table place_at_time_of_death add LASTNAME VARCHAR2(20);



Create this table on target in schema CONSCIOUSNESS :

create table location_at_time_of_death (
record_seq_no number,
place_id number,
supercluster varchar2(30),
galaxy varchar2(30)
);


ALTER TABLE location_at_time_of_death
add CONSTRAINT place_id_pk PRIMARY KEY (place_id);


create sequence location_at_time_of_death_seq
INCREMENT BY 1
START WITH 1
NOMAXVALUE
CACHE 20
;



alter table location_at_time_of_death add PERSON_ID NUMBER;
alter table location_at_time_of_death add INITIALNAME VARCHAR2(30);
alter table location_at_time_of_death add ENDNAME VARCHAR2(20);
alter table location_at_time_of_death add life_resulted_in VARCHAR2(100);

Output is as:


Source:

SQL> show user
USER is "MEDITATE"
SQL> create table place_at_time_of_death (
place_id number,
supercluster varchar2(30),
galaxy varchar2(30)
);
2 3 4 5
Table created.

SQL>


SQL> ALTER TABLE place_at_time_of_death
add CONSTRAINT place_id_pk PRIMARY KEY (place_id); 2

Table altered.


SQL> create sequence place_id_seq
increment by 1
start with 1
nomaxvalue
cache 20
; 2 3 4 5 6

Sequence created.



SQL> show user
USER is "MEDITATE"
SQL> alter table place_at_time_of_death add HUMAN_ID NUMBER;
alter table place_at_time_of_death add FIRSTNAME VARCHAR2(30);
alter table place_at_time_of_death add LASTNAME VARCHAR2(20);


Table altered.

SQL>
Table altered.

SQL>
Table altered.

SQL>

SQL>


Target:



SQL> create table location_at_time_of_death (
record_seq_no number,
place_id number,
supercluster varchar2(30),
galaxy varchar2(30)
);

2 3 4 5 6
Table created.

SQL> SQL>
ALTER TABLE location_at_time_of_death
add CONSTRAINT place_id_pk PRIMARY KEY (place_id);

SQL> 2
Table altered.

SQL>

SQL> SQL> create sequence location_at_time_of_death_seq
INCREMENT BY 1
START WITH 1
NOMAXVALUE
CACHE 20; 2 3 4 5

Sequence created.

SQL>


SQL> alter table location_at_time_of_death add PERSON_ID NUMBER;
alter table location_at_time_of_death add INITIALNAME VARCHAR2(30);
alter table location_at_time_of_death add ENDNAME VARCHAR2(20);

Table altered.

SQL>
Table altered.

SQL>
Table altered.

SQL>
SQL> alter table location_at_time_of_death add life_resulted_in VARCHAR2(100);

Table altered.

SQL>





Now, configure goldengate with ddl replication as:

On source do the following:

Enable supplemental logging at table level.
DBLOGIN USERID meditate, PASSWORD meditate
ADD TRANDATA meditate.place_at_time_of_death



Output as:

GGSCI (rac1.rac.meditate.com) 15> DBLOGIN USERID meditate, PASSWORD meditate
Successfully logged into database.

GGSCI (rac1.rac.meditate.com) 16> ADD TRANDATA meditate.place_at_time_of_death

Logging of supplemental redo data enabled for table MEDITATE.PLACE_AT_TIME_OF_DEATH.

GGSCI (rac1.rac.meditate.com) 17>



In LOGS:

2010-11-18 21:48:31 GGS INFO 399 Oracle GoldenGate Command Interpreter for Oracle: GGSCI command (oracle): ADD TRANDATA meditate.place_at_time_of_death.





Add extract as:
eplace
ADD EXTRACT eplace, TRANLOG, BEGIN NOW, threads 3

ADD EXTTRAIL /u01/app/oracle/product/goldengate/dirdat/pl, EXTRACT eplace


EDIT PARAMS eplace


EXTRACT eplace
USERID goldengate@simarsv1, PASSWORD AACAAAAAAAAAAAKAPATACEHBIGQGCFZCCDIGAEMCQFFBZHVC, ENCRYPTKEY default
TRANLOGOPTIONS ASMUSER sys@RAC1ASM, ASMPASSWORD AACAAAAAAAAAAAJASAOBIHRGNFGAYCKBHJPAGIXFGGBJUAXI, ENCRYPTKEY default
EXTTRAIL /u01/app/oracle/product/goldengate/dirdat/pl
-- DDL INCLUDE MAPPED
TABLE meditate.place_at_time_of_death;

Please note I am commenting line DDL INCLUDE MAPPED as it doesn't work when we use SOURCEDEFS parameter in replicat
i.e. when definition is different in source and target.


pplace
ADD EXTRACT pplace, EXTTRAILSOURCE /u01/app/oracle/product/goldengate/dirdat/pl

ADD RMTTRAIL /u01/app/oracle/product/goldengate/dirdat/pl, EXTRACT pplace

EDIT PARAMS pplace

EXTRACT pplace
RMTHOST goldengate, MGRPORT 7909
RMTTRAIL /u01/app/oracle/product/goldengate/dirdat/pl
PASSTHRU
TABLE meditate.place_at_time_of_death;




Output is as:

GGSCI (rac1.rac.meditate.com) 15> DBLOGIN USERID meditate, PASSWORD meditate
Successfully logged into database.

GGSCI (rac1.rac.meditate.com) 16> ADD TRANDATA meditate.place_at_time_of_death

Logging of supplemental redo data enabled for table MEDITATE.PLACE_AT_TIME_OF_DEATH.

GGSCI (rac1.rac.meditate.com) 17> ADD EXTRACT eplace, TRANLOG, BEGIN NOW, threads 3
EXTRACT added.


GGSCI (rac1.rac.meditate.com) 18> ADD EXTTRAIL /u01/app/oracle/product/goldengate/dirdat/pl, EXTRACT eplace
EXTTRAIL added.


GGSCI (rac1.rac.meditate.com) 19> EDIT PARAMS eplace

EXTRACT eplace
USERID goldengate@simarsv1, PASSWORD AACAAAAAAAAAAAKAPATACEHBIGQGCFZCCDIGAEMCQFFBZHVC, ENCRYPTKEY default
TRANLOGOPTIONS ASMUSER sys@RAC1ASM, ASMPASSWORD AACAAAAAAAAAAAJASAOBIHRGNFGAYCKBHJPAGIXFGGBJUAXI, ENCRYPTKEY default
EXTTRAIL /u01/app/oracle/product/goldengate/dirdat/pl
--DDL INCLUDE MAPPED
TABLE meditate.place_at_time_of_death;


GGSCI (rac1.rac.meditate.com) 20> ADD EXTRACT pplace, EXTTRAILSOURCE /u01/app/oracle/product/goldengate/dirdat/pl
EXTRACT added.


GGSCI (rac1.rac.meditate.com) 21> ADD RMTTRAIL /u01/app/oracle/product/goldengate/dirdat/pl, EXTRACT pplace
RMTTRAIL added.


GGSCI (rac1.rac.meditate.com) 22> EDIT PARAMS pplace

EXTRACT pplace
RMTHOST goldengate, MGRPORT 7909
RMTTRAIL /u01/app/oracle/product/goldengate/dirdat/pl
PASSTHRU
TABLE meditate.place_at_time_of_death;




GGSCI (rac1.rac.meditate.com) 23>
oracle : rac1.rac.meditate.com : @simar1 : /u01/app/oracle/product/goldengate
$






In logs it looks like:

2010-11-18 21:48:31 GGS INFO 399 Oracle GoldenGate Command Interpreter for Oracle: GGSCI command (oracle): ADD TRANDATA meditate.place_at_time_of_death.
2010-11-18 21:50:02 GGS INFO 399 Oracle GoldenGate Command Interpreter for Oracle: GGSCI command (oracle): ADD EXTRACT eplace TRANLOG, BEGIN NOW, threads 3.
2010-11-18 21:50:13 GGS INFO 399 Oracle GoldenGate Command Interpreter for Oracle: GGSCI command (oracle): ADD EXTTRAIL /u01/app/oracle/product/goldengate/dirdat/pl EXTRACT eplace.
2010-11-18 21:50:26 GGS INFO 399 Oracle GoldenGate Command Interpreter for Oracle: GGSCI command (oracle): EDIT PARAMS eplace.
2010-11-18 21:51:16 GGS INFO 399 Oracle GoldenGate Command Interpreter for Oracle: GGSCI command (oracle): ADD EXTRACT pplace EXTTRAILSOURCE /u01/app/oracle/product/goldengate/dirdat/pl.
2010-11-18 21:51:26 GGS INFO 399 Oracle GoldenGate Command Interpreter for Oracle: GGSCI command (oracle): ADD RMTTRAIL /u01/app/oracle/product/goldengate/dirdat/pl EXTRACT pplace.
2010-11-18 21:51:38 GGS INFO 399 Oracle GoldenGate Command Interpreter for Oracle: GGSCI command (oracle): EDIT PARAMS pplace.

============================================================

Create definition file here and scp to the target side.

I will create a file defeplace.prm under directroy $GOLDEN_GATE_INSALL/dirprm/defeplace.prm on source as:

cd /u01/app/oracle/product/goldengate/dirprm
vi defeplace.prm

DEFSFILE /u01/app/oracle/product/goldengate/dirdat/defeplace
USERID goldengate, PASSWORD AACAAAAAAAAAAAKAPATACEHBIGQGCFZCCDIGAEMCQFFBZHVC, ENCRYPTKEY default
TABLE meditate.place_at_time_of_death;

and then execute:

cd /u01/app/oracle/product/goldengate
./defgen paramfile dirprm/defeplace.prm


then scp this file to source as:
scp /u01/app/oracle/product/goldengate/dirdat/defeplace goldengate:/u01/app/oracle/product/goldengate/dirdat/defeplace

--------------------------------------------------------------

Output is as:

oracle : rac1.rac.meditate.com : @simar1 : /u01/app/oracle/product/goldengate/dirdat
$ cd /u01/app/oracle/product/goldengate

oracle : rac1.rac.meditate.com : @simar1 : /u01/app/oracle/product/goldengate
$ ./defgen paramfile dirprm/defeplace.prm

***********************************************************************
Oracle GoldenGate Table Definition Generator for Oracle
Version 10.4.0.19 Build 002
Linux, x64, 64bit (optimized), Oracle 11 on Sep 18 2009 00:09:13

Copyright (C) 1995, 2009, Oracle and/or its affiliates. All rights reserved.


Starting at 2010-11-25 02:52:07
***********************************************************************

Operating System Version:
Linux
Version #1 SMP Thu Sep 3 03:28:30 EDT 2009, Release 2.6.18-164.el5
Node: rac1.rac.meditate.com
Machine: x86_64
soft limit hard limit
Address Space Size : unlimited unlimited
Heap Size : unlimited unlimited
File Size : unlimited unlimited
CPU Time : unlimited unlimited

Process id: 21136

***********************************************************************
** Running with the following parameters **
***********************************************************************
DEFSFILE /u01/app/oracle/product/goldengate/dirdat/defeplace
USERID goldengate, PASSWORD ************************************************* ENCRYPTKEY default
TABLE meditate.place_at_time_of_death;
Retrieving definition for MEDITATE.PLACE_AT_TIME_OF_DEATH



Definitions generated for 1 tables in /u01/app/oracle/product/goldengate/dirdat/defeplace


oracle : rac1.rac.meditate.com : @simar1 : /u01/app/oracle/product/goldengate
$ scp /u01/app/oracle/product/goldengate/dirdat/defeplace goldengate:/u01/app/oracle/product/goldengate/dirdat/defeplace
oracle@goldengate's password:
defeplace 100% 1162 1.1KB/s 00:00

oracle : rac1.rac.meditate.com : @simar1 : /u01/app/oracle/product/goldengate
$
===========================================================

We will be using the following goldengate parameters in the parameter file.


Using EXCEPTIONSONLY
Use EXCEPTIONSONLY in an exceptions MAP statement intended for error handling. It causes
the MAP statement in which it is specified to be executed only if an error occurs for the last
record processed in the preceding MAP statement.
To use EXCEPTIONSONLY, set the REPERROR parameter to EXCEPTION for the error to be handled
as an exception. Make certain that the exceptions MAP statement specifies the same SOURCE
table as in the MAP statement for which the error is anticipated. Set the TARGET table to the
name of the exceptions table. For more information about REPERROR, see page 259.
The exceptions MAP statement must follow the MAP statement for which the error is
anticipated. For more information about using an exceptions MAP statement, see the
GoldenGate for Windows and UNIX Administrator Guide.
Syntax MAP , TARGET
, EXCEPTIONSONLY



REPERROR
Valid for Replicat
Use the REPERROR parameter to control how Replicat responds to errors. You can use one
REPERROR statement to handle most errors in a default manner, while using one or more
other REPERROR statements to handle specific errors differently. For example, you can ignore
duplicate-record errors but abort processing in all other cases.
In the syntax shown, note that the , specification must be within
parentheses.

This parameter has many options but I will discuss following 2 here only:

DISCARD Log the error to the discard file but continue processing the
transaction and subsequent transactions.

EXCEPTION Handle the error as an exception. In anticipation of possible errors,
you can create an exceptions MAP statement that executes only after
an error. Use that MAP statement, for example, to map columns
from a failed update statement into a “missing update” table. In the
parameter file, specify the exceptions MAP sta



DISCARDFILE
Valid for Extract and Replicat
Use the DISCARDFILE parameter to generate a discard file to which GoldenGate can log
records that it cannot process. Records can be discarded for several reasons. For example,
a record is discarded if the underlying table structure changed since the record was written
to the trail. You can use the discard file to help you identify the cause of processing errors.
Each entry in the discard file contains the discarded record buffer and an error code
indicating the reason. GoldenGate creates the specified discard file in the dirrpt subdirectory
of the GoldenGate installation directory. You can view it with a text editor or by
using the following command in GGSCI.
VIEW REPORT
Where: is the fully qualified name of the discard file.
To prevent having to perform manual maintenance of discard files, use either the PURGE or
APPEND option. Otherwise, you must specify a different discard file name before starting
each process run, because GoldenGate will not write to an existing discard file.



DISCARDROLLOVER
Valid for Extract and Replicat
Use the DISCARDROLLOVER parameter to set a schedule for aging discard files. For long or
continuous runs, setting an aging schedule prevents the discard file from filling up and
causing the process to abend, and it provides a predictable set of archives that can be
included in your archiving routine.
When the DISCARDROLLOVER age point is reached, a new discard file is created, and old files
are renamed in the format of ., where:
? is the name of the Extract or Replicat group
? is a number that gets incremented by one each time a new file is created, for
example: myext0.dsc, myext1.dsc, myext2.dsc, and so forth.
You can specify a time of day, a day of the week, or both. Specifying just a time of day (AT
option) without a day of the week (ON option) generates a discard file at the specified time
every day.



ALLOWDUPTARGETMAP | NOALLOWDUPTARGETMAP
Valid for Replicat
Use the ALLOWDUPTARGETMAP and NOALLOWDUPTARGETMAP parameters to control whether or
not duplicate MAP statements for the same source and target objects are accepted in a
parameter file.



Add the replicat like following on the targer server, please note here we are replicating just the inserts here
we will modify the parameter file to replicate deletes and updates later in the tutorial:

ADD REPLICAT rplace, EXTTRAIL /u01/app/oracle/product/goldengate/dirdat/pl


EDIT PARAMS rplace

REPLICAT rplace
SOURCEDEFS /u01/app/oracle/product/goldengate/dirdat/defeplace
DISCARDFILE /u01/app/oracle/product/goldengate/dirdat/location_at_time_of_death_err, purge
DISCARDROLLOVER ON sunday
USERID goldengate, PASSWORD AACAAAAAAAAAAAKAPATACEHBIGQGCFZCCDIGAEMCQFFBZHVC, ENCRYPTKEY default
REPERROR (DEFAULT, DISCARD)
GETINSERTS
IGNOREDELETES
IGNOREUPDATES
MAP meditate.place_at_time_of_death, TARGET CONSCIOUSNESS.location_at_time_of_death, &
sqlexec (id record_seq_lookup, query "select CONSCIOUSNESS.location_at_time_of_death_seq.NEXTVAL record_seq from dual", noparams), &
sqlexec (id life_resulted_in_lookup, query "select deed_result from CONSCIOUSNESS.RESULTS &
where deed_id = (select DEED_ID_AT_DEATH from CONSCIOUSNESS.TENURE where &
PERSON_ID=(:humanid_topass) and INITIALNAME=:fist and ENDNAME=:lastname_topass)", &
params(humanid_topass=HUMAN_ID,fist=FIRSTNAME,lastname_topass=LASTNAME), ERROR RAISE, TRACE ALL), &
COLMAP (RECORD_SEQ_NO=@getval (record_seq_lookup.record_seq), &
PLACE_ID=PLACE_ID, &
SUPERCLUSTER=SUPERCLUSTER, &
GALAXY=GALAXY, &
PERSON_ID=HUMAN_ID, &
INITIALNAME=FIRSTNAME, &
ENDNAME=LASTNAME, &
LIFE_RESULTED_IN=@getval (life_resulted_in_lookup.deed_result)), &
KEYCOLS (PLACE_ID) ;



Explanation for few parameters that we are using here:
In following block:

"sqlexec (id record_seq_lookup, query "select CONSCIOUSNESS.location_at_time_of_death_seq.NEXTVAL record_seq from dual", noparams), &"

"id" declares the alias
"record_seq_lookup" is alias name of the block and can be anything.
"query" is the query that will be executed
"record_seq" is the alias for "CONSCIOUSNESS.location_at_time_of_death_seq.NEXTVAL" and can be anything
i.e whatever is returned will be stored in "record_seq" and when we want to retrive teh value in later part of teh parameter file
reference it as record_seq_lookup.record_seq
i.e block_alias_name.alias_name
"noparams" means we are not passing any parameters to this sql being executed.


and in the explanation for teh following block is :

" sqlexec (id life_resulted_in_lookup, query "select deed_result from CONSCIOUSNESS.RESULTS &
where deed_id = (select DEED_ID_AT_DEATH from CONSCIOUSNESS.TENURE where &
PERSON_ID=(:humanid_topass) and INITIALNAME=:fist and ENDNAME=:lastname_topass)", &
params(humanid_topass=HUMAN_ID,fist=FIRSTNAME,lastname_topass=LASTNAME), ERROR RAISE, TRACE ALL), & "

Only thing here is we are passing parameters to the sql and they are:
:humanid_topass
:fist
:lastname_topass

the values for them are
humanid_topass=HUMAN_ID
fist=FIRSTNAME
lastname_topass=LASTNAME






Now lets start the replicat as:

start replicat rplace


Output is as:

GGSCI (goldengate) 14> ADD REPLICAT rplace, EXTTRAIL /u01/app/oracle/product/goldengate/dirdat/pl
REPLICAT added.


GGSCI (goldengate) 15> EDIT PARAMS rplace



Output in logs is as:

2010-11-25 02:23:54 GGS INFO 399 Oracle GoldenGate Command Interpreter for Oracle: GGSCI command (oracle): ADD REPLICAT rplace EXTTRAIL /u01/app/oracle/product/goldengate/dirdat/pl.
2010-11-25 02:24:19 GGS INFO 399 Oracle GoldenGate Command Interpreter for Oracle: GGSCI command (oracle): EDIT PARAMS rplace.
2010-11-25 02:26:00 GGS INFO 399 Oracle GoldenGate Command Interpreter for Oracle: GGSCI command (oracle): start replicat rplace.
2010-11-25 02:26:00 GGS INFO 301 Oracle GoldenGate Manager for Oracle, mgr.prm: Command received from GGSCI on host 192.168.1.169 (START REPLICAT RPLACE ).
2010-11-25 02:26:00 GGS INFO 302 Oracle GoldenGate Manager for Oracle, mgr.prm: REPLICAT RPLACE starting.
2010-11-25 02:26:00 GGS INFO 320 Oracle GoldenGate Delivery for Oracle, rplace.prm: REPLICAT RPLACE starting.
2010-11-25 02:26:01 GGS INFO 320 Oracle GoldenGate Delivery for Oracle, rplace.prm: REPLICAT RPLACE started.




Now lets start the extract on the source side as:

start extract EPLACE
start extract PPLACE


Output is as:

GGSCI (rac1.rac.meditate.com) 5> start extract EPLACE

Sending START request to MANAGER ...
EXTRACT EPLACE starting


GGSCI (rac1.rac.meditate.com) 6> start extract PPLACE

Sending START request to MANAGER ...
EXTRACT PPLACE starting


GGSCI (rac1.rac.meditate.com) 7>




In source, output in logs is as:

2010-11-25 03:12:30 GGS INFO 399 Oracle GoldenGate Command Interpreter for Oracle: GGSCI command (oracle): start extract EPLACE.
2010-11-25 03:12:30 GGS INFO 301 Oracle GoldenGate Manager for Oracle, mgr.prm: Command received from GGSCI on host 192.168.1.176 (START EXTRACT EPLACE ).
2010-11-25 03:12:30 GGS INFO 302 Oracle GoldenGate Manager for Oracle, mgr.prm: EXTRACT EPLACE starting.
2010-11-25 03:12:30 GGS INFO 310 Oracle GoldenGate Capture for Oracle, eplace.prm: EXTRACT EPLACE starting.
2010-11-25 03:15:01 GGS INFO Z0-016 Oracle GoldenGate Capture for Oracle, eplace.prm: Default thread stack size: 33554432.
2010-11-25 03:15:21 GGS INFO 310 Oracle GoldenGate Capture for Oracle, eplace.prm: EXTRACT EPLACE started.
2010-11-25 03:15:21 GGS INFO 112 Oracle GoldenGate Capture for Oracle, eplace.prm: No recovery is required for target file /u01/app/oracle/product/goldengate/dirdat/pl000000, at RBA 0 (file not opened).
2010-11-25 03:15:21 GGS INFO Z0-05M Oracle GoldenGate Capture for Oracle, eplace.prm: Output file /u01/app/oracle/product/goldengate/dirdat/pl is using format RELEASE 10.4.
2010-11-25 03:15:36 GGS INFO 399 Oracle GoldenGate Command Interpreter for Oracle: GGSCI command (oracle): start extract PPLACE.
2010-11-25 03:15:37 GGS INFO 301 Oracle GoldenGate Manager for Oracle, mgr.prm: Command received from GGSCI on host 192.168.1.176 (START EXTRACT PPLACE ).
2010-11-25 03:15:37 GGS INFO 302 Oracle GoldenGate Manager for Oracle, mgr.prm: EXTRACT PPLACE starting.
2010-11-25 03:15:37 GGS INFO 310 Oracle GoldenGate Capture for Oracle, pplace.prm: EXTRACT PPLACE starting.
2010-11-25 03:15:37 GGS INFO 310 Oracle GoldenGate Capture for Oracle, pplace.prm: EXTRACT PPLACE started.
2010-11-25 03:15:43 GGS INFO 406 Oracle GoldenGate Capture for Oracle, pplace.prm: Socket buffer size set to 27985 (flush size 27985).
2010-11-25 03:15:57 GGS INFO 112 Oracle GoldenGate Capture for Oracle, pplace.prm: No recovery is required for target file /u01/app/oracle/product/goldengate/dirdat/pl000000, at RBA 0 (file not opened).
2010-11-25 03:15:57 GGS INFO Z0-05M Oracle GoldenGate Capture for Oracle, pplace.prm: Output file /u01/app/oracle/product/goldengate/dirdat/pl is using format RELEASE 10.4.



On target we have following in logs:

2010-11-25 02:43:40 GGS INFO 301 Oracle GoldenGate Manager for Oracle, mgr.prm: Command received from EXTRACT on host 192.168.1.176 (START SERVER CPU -1 PRI -1 PARAMS ).
2010-11-25 02:43:40 GGS INFO 302 Oracle GoldenGate Manager for Oracle, mgr.prm: Manager started collector process (Port 7848).
2010-11-25 02:43:40 GGS INFO 373 Oracle GoldenGate Collector, port 7848: Waiting for connection (started dynamically).
2010-11-25 02:43:59 GGS INFO 373 Oracle GoldenGate Collector: Connected to 192.168.1.176:61301.
2010-11-25 02:43:59 GGS INFO 370 Oracle GoldenGate Collector, port 7848: Opening /u01/app/oracle/product/goldengate/dirdat/pl000000 (byte -1, current EOF 0).






Now we will test the replication:

On source side we have:

SQL> desc place_AT_TIME_OF_DEATH
Name Null? Type
----------------------------------------- -------- ----------------------------
PLACE_ID NOT NULL NUMBER
SUPERCLUSTER VARCHAR2(30)
GALAXY VARCHAR2(30)
HUMAN_ID NUMBER
FIRSTNAME VARCHAR2(30)
LASTNAME VARCHAR2(20)

SQL> insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'COMA',3,'AB','CD');

1 row created.

SQL> insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'COMA',3,'MN','OP');

1 row created.

SQL> insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'COMA',3,'QR','ST');

1 row created.

SQL> insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'COMA',2,'IJ','KL');

1 row created.

SQL> commit;

Commit complete.

SQL>


On target side we got:

Before insert on source:

SQL> select * from LOCATION_AT_TIME_OF_DEATH;

no rows selected



After insert on source its replicated to target as:


SQL> SQL> set line 300
SQL> l
1* select * from LOCATION_AT_TIME_OF_DEATH
SQL> /

RECORD_SEQ_NO PLACE_ID SUPERCLUSTER GALAXY PERSON_ID INITIALNAME ENDNAME LIFE_RESULTED_IN
------------- ---------- ------------------------------ ------------------------------ ---------- ------------------------------ -------------------- ----------------------------------------------------------------------------------------------------
2 7 COMA 3 AB CD Becomes snake in next incarnations
3 8 COMA 3 MN OP Becomes prostitute in next incarnations
4 9 COMA 3 QR ST Liberated
5 10 COMA 2 IJ KL Becomes pig in next incarnations

4 rows selected.

SQL>


Now, I will change the DDL of the table on the source and target databases to have more data recorded in this table to do little bit more
complex replication.
Before changing the DDL, I will stop extract and replicat processes for this table on both source and target.

On source
stop extract eplace
stop extract pplace

Output on source is as:

GGSCI (rac1.rac.meditate.com) 42> stop extract EPLACE

Sending STOP request to EXTRACT EPLACE ...
Request processed.


GGSCI (rac1.rac.meditate.com) 43> stop extract PPLACE

Sending STOP request to EXTRACT PPLACE ...
Request processed.


GGSCI (rac1.rac.meditate.com) 44>



On target
stop replicat RPLACE

Output on target is as:

GGSCI (goldengate) 101> stop replicat RPLACE

Sending STOP request to REPLICAT RPLACE ...
Request processed.


GGSCI (goldengate) 102>



Now on source do the following under schmea meditate:

desc place_at_time_of_death
alter table place_at_time_of_death add star varchar2(30);
alter table place_at_time_of_death add planet varchar2(30);
alter table place_at_time_of_death add race varchar2(30);
alter table place_at_time_of_death add continent varchar2(30);
alter table place_at_time_of_death add province varchar2(30);
alter table place_at_time_of_death add city varchar2(30);
desc place_at_time_of_death


Output on source is as:

SQL> desc place_at_time_of_death
Name Null? Type
----------------------------------------- -------- ----------------------------
PLACE_ID NOT NULL NUMBER
SUPERCLUSTER VARCHAR2(30)
GALAXY VARCHAR2(30)
HUMAN_ID NUMBER
FIRSTNAME VARCHAR2(30)
LASTNAME VARCHAR2(20)

SQL> alter table place_at_time_of_death add star varchar2(30);


Table altered.

SQL> SQL> alter table place_at_time_of_death add planet varchar2(30);

Table altered.

SQL> alter table place_at_time_of_death add race varchar2(30);

Table altered.

SQL> alter table place_at_time_of_death add continent varchar2(30);

Table altered.

SQL> alter table place_at_time_of_death add province varchar2(30);

Table altered.

SQL> alter table place_at_time_of_death add city varchar2(30);

Table altered.

SQL> desc place_at_time_of_death
Name Null? Type
----------------------------------------- -------- ----------------------------
PLACE_ID NOT NULL NUMBER
SUPERCLUSTER VARCHAR2(30)
GALAXY VARCHAR2(30)
HUMAN_ID NUMBER
FIRSTNAME VARCHAR2(30)
LASTNAME VARCHAR2(20)
STAR VARCHAR2(30)
PLANET VARCHAR2(30)
RACE VARCHAR2(30)
CONTINENT VARCHAR2(30)
PROVINCE VARCHAR2(30)
CITY VARCHAR2(30)

SQL>



and now do the following on target under CONSCIOUSNESS:

desc location_at_time_of_death
alter table location_at_time_of_death add star varchar2(30);
alter table location_at_time_of_death add planet varchar2(30);
alter table location_at_time_of_death add race varchar2(30);
alter table location_at_time_of_death add continent varchar2(30);
alter table location_at_time_of_death add province varchar2(30);
alter table location_at_time_of_death add city varchar2(30);
desc location_at_time_of_death


Output on target is as:
SQL> show user
USER is "CONSCIOUSNESS"
SQL> desc LOCATION_AT_TIME_OF_DEATH
Name Null? Type
----------------------------- -------- --------------------
RECORD_SEQ_NO NUMBER
PLACE_ID NOT NULL NUMBER
SUPERCLUSTER VARCHAR2(30)
GALAXY VARCHAR2(30)
PERSON_ID NUMBER
INITIALNAME VARCHAR2(30)
ENDNAME VARCHAR2(20)
LIFE_RESULTED_IN VARCHAR2(100)

SQL> alter table location_at_time_of_death add star varchar2(30);

Table altered.

SQL> alter table location_at_time_of_death add planet varchar2(30);

Table altered.

SQL> alter table location_at_time_of_death add race varchar2(30);

Table altered.

SQL> alter table location_at_time_of_death add continent varchar2(30);

Table altered.

SQL> alter table location_at_time_of_death add province varchar2(30);

Table altered.

SQL> alter table location_at_time_of_death add city varchar2(30);

Table altered.

SQL> desc location_at_time_of_death
Name Null? Type
----------------------------- -------- --------------------
RECORD_SEQ_NO NUMBER
PLACE_ID NOT NULL NUMBER
SUPERCLUSTER VARCHAR2(30)
GALAXY VARCHAR2(30)
PERSON_ID NUMBER
INITIALNAME VARCHAR2(30)
ENDNAME VARCHAR2(20)
LIFE_RESULTED_IN VARCHAR2(100)
STAR VARCHAR2(30)
PLANET VARCHAR2(30)
RACE VARCHAR2(30)
CONTINENT VARCHAR2(30)
PROVINCE VARCHAR2(30)
CITY VARCHAR2(30)

SQL>



Now we will need to create the definition file on source again and scp to target as:

cd /u01/app/oracle/product/goldengate/dirprm
vi defeplace.prm

DEFSFILE /u01/app/oracle/product/goldengate/dirdat/defeplace
USERID goldengate, PASSWORD AACAAAAAAAAAAAKAPATACEHBIGQGCFZCCDIGAEMCQFFBZHVC, ENCRYPTKEY default
TABLE meditate.place_at_time_of_death;

and then execute:

mv /u01/app/oracle/product/goldengate/dirdat/defeplace /u01/app/oracle/product/goldengate/dirdat/defeplace.case1
cd /u01/app/oracle/product/goldengate
./defgen paramfile dirprm/defeplace.prm


then scp this file to source as:
scp /u01/app/oracle/product/goldengate/dirdat/defeplace goldengate:/u01/app/oracle/product/goldengate/dirdat/defeplace


Output is as:
oracle : rac1.rac.meditate.com : @simar1 : /u01/app/oracle/product/goldengate
$ mv /u01/app/oracle/product/goldengate/dirdat/defeplace /u01/app/oracle/product/goldengate/dirdat/defeplace.case1

oracle : rac1.rac.meditate.com : @simar1 : /u01/app/oracle/product/goldengate
$ cd /u01/app/oracle/product/goldengate

oracle : rac1.rac.meditate.com : @simar1 : /u01/app/oracle/product/goldengate
$ ./defgen paramfile dirprm/defeplace.prm

***********************************************************************
Oracle GoldenGate Table Definition Generator for Oracle
Version 10.4.0.19 Build 002
Linux, x64, 64bit (optimized), Oracle 11 on Sep 18 2009 00:09:13

Copyright (C) 1995, 2009, Oracle and/or its affiliates. All rights reserved.


Starting at 2010-11-26 00:34:43
***********************************************************************

Operating System Version:
Linux
Version #1 SMP Thu Sep 3 03:28:30 EDT 2009, Release 2.6.18-164.el5
Node: rac1.rac.meditate.com
Machine: x86_64
soft limit hard limit
Address Space Size : unlimited unlimited
Heap Size : unlimited unlimited
File Size : unlimited unlimited
CPU Time : unlimited unlimited

Process id: 7598

***********************************************************************
** Running with the following parameters **
***********************************************************************
DEFSFILE /u01/app/oracle/product/goldengate/dirdat/defeplace
USERID goldengate, PASSWORD ************************************************* ENCRYPTKEY default
TABLE meditate.place_at_time_of_death;
Retrieving definition for MEDITATE.PLACE_AT_TIME_OF_DEATH



Definitions generated for 1 tables in /u01/app/oracle/product/goldengate/dirdat/defeplace


oracle : rac1.rac.meditate.com : @simar1 : /u01/app/oracle/product/goldengate
$ scp /u01/app/oracle/product/goldengate/dirdat/defeplace goldengate:/u01/app/oracle/product/goldengate/dirdat/defeplace
oracle@goldengate's password:
defeplace 100% 1667 1.6KB/s 00:00

oracle : rac1.rac.meditate.com : @simar1 : /u01/app/oracle/product/goldengate
$



Now lets fix our golden gate parameter file for replicat rplace on source so that we can still replicate the inserts:

EDIT PARAMS rplace

REPLICAT rplace
SOURCEDEFS /u01/app/oracle/product/goldengate/dirdat/defeplace
DISCARDFILE /u01/app/oracle/product/goldengate/dirdat/location_at_time_of_death_err, purge
DISCARDROLLOVER ON sunday
USERID goldengate, PASSWORD AACAAAAAAAAAAAKAPATACEHBIGQGCFZCCDIGAEMCQFFBZHVC, ENCRYPTKEY default
REPERROR (DEFAULT, DISCARD)
GETINSERTS
IGNOREDELETES
IGNOREUPDATES
MAP meditate.place_at_time_of_death, TARGET CONSCIOUSNESS.location_at_time_of_death, &
sqlexec (id record_seq_lookup, query "select CONSCIOUSNESS.location_at_time_of_death_seq.NEXTVAL record_seq from dual", noparams), &
sqlexec (id life_resulted_in_lookup, query "select deed_result from CONSCIOUSNESS.RESULTS &
where deed_id = (select DEED_ID_AT_DEATH from CONSCIOUSNESS.TENURE where &
PERSON_ID=(:humanid_topass) and INITIALNAME=:fist and ENDNAME=:lastname_topass)", &
params(humanid_topass=HUMAN_ID,fist=FIRSTNAME,lastname_topass=LASTNAME), ERROR RAISE, TRACE ALL), &
COLMAP (RECORD_SEQ_NO=@getval (record_seq_lookup.record_seq), &
PLACE_ID=PLACE_ID, &
SUPERCLUSTER=SUPERCLUSTER, &
GALAXY=GALAXY, &
PERSON_ID=HUMAN_ID, &
INITIALNAME=FIRSTNAME, &
ENDNAME=LASTNAME, &
LIFE_RESULTED_IN=@getval (life_resulted_in_lookup.deed_result), &
STAR=STAR, &
PLANET=PLANET, &
RACE=RACE, &
CONTINENT=CONTINENT, &
PROVINCE=PROVINCE, &
CITY=CITY), &
KEYCOLS (PLACE_ID) ;


Now lets start the extraction and replication processes on both source and target as:

On source:
start extract eplace
start extract pplace


Output is as:

GGSCI (rac1.rac.meditate.com) 52> start extract eplace

Sending START request to MANAGER ...
EXTRACT EPLACE starting


GGSCI (rac1.rac.meditate.com) 53> start extract pplace

Sending START request to MANAGER ...
EXTRACT PPLACE starting


GGSCI (rac1.rac.meditate.com) 54>



On target
start replicat rplace



Output is as:

GGSCI (goldengate) 102> start replicat rplace

Sending START request to MANAGER ...
REPLICAT RPLACE starting


GGSCI (goldengate) 103>



Now lets do some inserts to see if our replication is still working:


On source we have:
SQL> insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'SHAPLEY',1,'AB','CD');

1 row created.

SQL> commit;

Commit complete.

SQL>





On target we have:

1* select count(*) from location_at_time_of_death
SQL> /

COUNT(*)
----------
5

SQL>


Lets insert the other records as:

On source as:

insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'CENTAURUS',1,'EF','GH');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'SCULPTOR',1,'IJ','KL');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'HYDA',1,'MN','OP');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'PERSEUS-PISCES',1,'QR','ST');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'LEO',2,'AB','CD');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'URSA MAJOR',2,'EF','GH');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'PISCES-CETUS',2,'MN','OP');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'PAVO INDUS',2,'QR','ST');

Output on source is as:
SQL> insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'CENTAURUS',1,'EF','GH');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'SCULPTOR',1,'IJ','KL');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'HYDA',1,'MN','OP');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'PERSEUS-PISCES',1,'QR','ST');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'LEO',2,'AB','CD');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'URSA MAJOR',2,'EF','GH');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'PISCES-CETUS',2,'MN','OP');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'PAVO INDUS',2,'QR','ST');


1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL> SQL> commit ;

Commit complete.

SQL> select count(*) from place_at_time_of_death;

COUNT(*)
----------
13

SQL>



On target we have:
SQL> l
1* select count(*) from location_at_time_of_death
SQL> /

COUNT(*)
----------
13

SQL>



So, our replication is working.





On source do following:
select count(*) from life;
insert into life values (4,'AB','CD',SYSDATE - 23725,65,1);
insert into life values (4,'EF','GH',SYSDATE - 23725,65,1);
insert into life values (4,'IJ','KL',SYSDATE - 23725,65,2);
insert into life values (4,'MN','OP',SYSDATE - 23725,65,2);
insert into life values (4,'QR','ST',SYSDATE - 23725,65,3);
insert into life values (5,'AB','CD',SYSDATE - 23725,65,3);
insert into life values (5,'EF','GH',SYSDATE - 23725,65,4);
insert into life values (5,'IJ','KL',SYSDATE - 23725,65,4);
insert into life values (5,'MN','OP',SYSDATE - 23725,65,5);
insert into life values (5,'QR','ST',SYSDATE - 23725,65,5);
insert into life values (6,'AB','CD',SYSDATE - 23725,65,2);
insert into life values (6,'EF','GH',SYSDATE - 23725,65,2);
insert into life values (6,'IJ','KL',SYSDATE - 23725,65,3);
insert into life values (6,'MN','OP',SYSDATE - 23725,65,3);
insert into life values (6,'QR','ST',SYSDATE - 23725,65,4);
insert into life values (7,'AB','CD',SYSDATE - 23725,65,2);
insert into life values (7,'EF','GH',SYSDATE - 23725,65,2);
insert into life values (7,'IJ','KL',SYSDATE - 23725,65,2);
insert into life values (7,'MN','OP',SYSDATE - 23725,65,2);
insert into life values (7,'QR','ST',SYSDATE - 23725,65,2);
insert into life values (8,'AB','CD',SYSDATE - 23725,65,2);
insert into life values (8,'EF','GH',SYSDATE - 23725,65,5);
insert into life values (8,'IJ','KL',SYSDATE - 23725,65,5);
insert into life values (8,'MN','OP',SYSDATE - 23725,65,5);
insert into life values (8,'QR','ST',SYSDATE - 23725,65,5);
select count(*) from life;


Output is as:

SQL> select count(*) from life;
insert into life values (4,'AB','CD',SYSDATE - 23725,65,1);
insert into life values (4,'EF','GH',SYSDATE - 23725,65,1);
insert into life values (4,'IJ','KL',SYSDATE - 23725,65,2);
insert into life values (4,'MN','OP',SYSDATE - 23725,65,2);
insert into life values (4,'QR','ST',SYSDATE - 23725,65,3);
insert into life values (5,'AB','CD',SYSDATE - 23725,65,3);
insert into life values (5,'EF','GH',SYSDATE - 23725,65,4);
insert into life values (5,'IJ','KL',SYSDATE - 23725,65,4);
insert into life values (5,'MN','OP',SYSDATE - 23725,65,5);
insert into life values (5,'QR','ST',SYSDATE - 23725,65,5);
insert into life values (6,'AB','CD',SYSDATE - 23725,65,2);
insert into life values (6,'EF','GH',SYSDATE - 23725,65,2);
insert into life values (6,'IJ','KL',SYSDATE - 23725,65,3);
insert into life values (6,'MN','OP',SYSDATE - 23725,65,3);
insert into life values (6,'QR','ST',SYSDATE - 23725,65,4);
insert into life values (7,'AB','CD',SYSDATE - 23725,65,2);
insert into life values (7,'EF','GH',SYSDATE - 23725,65,2);
insert into life values (7,'IJ','KL',SYSDATE - 23725,65,2);
insert into life values (7,'MN','OP',SYSDATE - 23725,65,2);
insert into life values (7,'QR','ST',SYSDATE - 23725,65,2);
insert into life values (8,'AB','CD',SYSDATE - 23725,65,2);

insert into life values (8,'EF','GH',SYSDATE - 23725,65,5);
insert into life values (8,'IJ','KL',SYSDATE - 23725,65,5);
insert into life values (8,'MN','OP',SYSDATE - 23725,65,5);
insert into life values (8,'QR','ST',SYSDATE - 23725,65,5);
select count(*) from life;
COUNT(*)
----------
15

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
COUNT(*)
----------
40

SQL> commit;

Commit complete.

SQL>




On target
select count(*) from tenure;

SQL> l
1* select count(*) from tenure
SQL> /

COUNT(*)
----------
40

SQL>


Lets do few more on source as:

insert into life values (9,'AB','CD',SYSDATE - 23725,65,2);
insert into life values (9,'EF','GH',SYSDATE - 23725,65,5);
insert into life values (9,'IJ','KL',SYSDATE - 23725,65,5);
insert into life values (9,'MN','OP',SYSDATE - 23725,65,5);
insert into life values (9,'QR','ST',SYSDATE - 23725,65,5);

Output is:

SQL> insert into life values (9,'AB','CD',SYSDATE - 23725,65,2);
insert into life values (9,'EF','GH',SYSDATE - 23725,65,5);
insert into life values (9,'IJ','KL',SYSDATE - 23725,65,5);
insert into life values (9,'MN','OP',SYSDATE - 23725,65,5);
insert into life values (9,'QR','ST',SYSDATE - 23725,65,5);

1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL>
1 row created.

SQL> commit;

Commit complete.

SQL>




and on target its:

SQL> select count(*) from tenure;

COUNT(*)
----------
45

SQL>






Now on source do the following:

insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'SEXTANS',3,'EF','GH');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'COLUMBA',3,'IJ','KL');


insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'HOROLOGUM',4,'AB','CD');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'CAPRICORNOUS',4,'EF','GH');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'HERCULES',4,'IJ','KL');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'BOOTES',4,'MN','OP');
insert into place_at_time_of_death (place_id,supercluster,human_id,firstname,lastname) values (place_id_seq.nextval,'CORONA-BOREALIS',4,'QR','ST');
insert into place_at_time_of_death (place_id,supercluster,galaxy,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','N4365',5,'AB','CD');
insert into place_at_time_of_death (place_id,supercluster,galaxy,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','M49',5,'EF','GH');
insert into place_at_time_of_death (place_id,supercluster,galaxy,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','N4526',5,'IJ','KL');
insert into place_at_time_of_death (place_id,supercluster,galaxy,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','N4535',5,'MN','OP');
insert into place_at_time_of_death (place_id,supercluster,galaxy,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','N4429',5,'QR','ST');
insert into place_at_time_of_death (place_id,supercluster,galaxy,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','M58',6,'AB','CD');
insert into place_at_time_of_death (place_id,supercluster,galaxy,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','M59',6,'EF','GH');
insert into place_at_time_of_death (place_id,supercluster,galaxy,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','M60',6,'IJ','KL');
insert into place_at_time_of_death (place_id,supercluster,galaxy,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','N4762',6,'MN','OP');
insert into place_at_time_of_death (place_id,supercluster,galaxy,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','M87',6,'QR','ST');
insert into place_at_time_of_death (place_id,supercluster,galaxy,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','M89',7,'AB','CD');
insert into place_at_time_of_death (place_id,supercluster,galaxy,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','N90',7,'EF','GH');
insert into place_at_time_of_death (place_id,supercluster,galaxy,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','N4654',7,'IJ','KL');
insert into place_at_time_of_death (place_id,supercluster,galaxy,star,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','SOL',7,'MN','OP');
insert into place_at_time_of_death (place_id,supercluster,galaxy,star,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','CHARA',7,'QR','ST');

insert into place_at_time_of_death (place_id,supercluster,galaxy,star,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','SCORPII',7,'AB','CD');
insert into place_at_time_of_death (place_id,supercluster,galaxy,star,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','37 GEMINORM',7,'EF','GH');
insert into place_at_time_of_death (place_id,supercluster,galaxy,star,planet,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','SUN','MERCURY',7,'IJ','KL');
insert into place_at_time_of_death (place_id,supercluster,galaxy,star,planet,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','SUN','VENUS',7,'MN','OP');
insert into place_at_time_of_death (place_id,supercluster,galaxy,star,planet,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','SUN','MARS',7,'QR','ST');
insert into place_at_time_of_death (place_id,supercluster,galaxy,star,planet,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','SUN','JUPITER',8,'AB','CD');
insert into place_at_time_of_death (place_id,supercluster,galaxy,star,planet,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','SUN','SATURAN',8,'EF','GH');
insert into place_at_time_of_death (place_id,supercluster,galaxy,star,planet,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','SUN','URANUS',8,'IJ','KL');
insert into place_at_time_of_death (place_id,supercluster,galaxy,star,planet,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','SUN','NEPTUNE',8,'MN','OP');
insert into place_at_time_of_death (place_id,supercluster,galaxy,star,planet,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','SUN','PLUTO',8,'QR','ST');


insert into place_at_time_of_death (place_id,supercluster,galaxy,star,planet,race,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','SUN','EARTH','BIRD',9,'AB','CD');
insert into place_at_time_of_death (place_id,supercluster,galaxy,star,planet,race,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','SUN','EARTH','HUMAN',9,'EF','GH');
insert into place_at_time_of_death (place_id,supercluster,galaxy,star,planet,race,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','SUN','EARTH','HUMAN',9,'IJ','KL');
insert into place_at_time_of_death (place_id,supercluster,galaxy,star,planet,race,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','SUN','EARTH','HUMAN',9,'MN','OP');
insert into place_at_time_of_death (place_id,supercluster,galaxy,star,planet,race,human_id,firstname,lastname) values (place_id_seq.nextval,'VIRGO','MILKY WAY','SUN','EARTH','HUMAN',9,'QR','ST');


Output in source:
SQL> select count(*) from place_at_time_of_death;

COUNT(*)
----------
50

SQL>



In target the output is as:
SQL> select count(*) from location_at_time_of_death;

COUNT(*)
----------
50

SQL>



This human body has been given to you. This is your chance to meet the Lord of the Universe. Nothing else will work. Join the Saadh Sangat, the Company of the Holy; vibrate and meditate on the Jewel of the Naam. || 1|| Make every effort to cross over this terrifying world-ocean


No comments:

Post a Comment