Incremental Loading Without Date fields in source
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 14
- Joined: Thu Jun 09, 2011 7:24 pm
- Location: USA
Incremental Loading Without Date fields in source
Hi
my source is Sql server and Target oracle
i am trying to design a job to load Delta records ..but the source doesn't have any date fields ..so whenever i am loading data source fetching all the records...is there any way that i can fetch latest records from source
in other words
today i loaded 100 records after initial load...when running the job tomorrow i need only records fof tomorrow i don't want to fetch yesterday's 100 records again
my source is Sql server and Target oracle
i am trying to design a job to load Delta records ..but the source doesn't have any date fields ..so whenever i am loading data source fetching all the records...is there any way that i can fetch latest records from source
in other words
today i loaded 100 records after initial load...when running the job tomorrow i need only records fof tomorrow i don't want to fetch yesterday's 100 records again
ram
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Really you have again neglected to provide us with sufficient information.
There may or may not be a mechanism for solving this problem. It really depends whether there is some way in the source data for identifying the delta.
For example if the source has an auto-incrementing key you can store the highest key retrieved today and tomorrow fetch just those records with a key value greater than this.
There may or may not be a mechanism for solving this problem. It really depends whether there is some way in the source data for identifying the delta.
For example if the source has an auto-incrementing key you can store the highest key retrieved today and tomorrow fetch just those records with a key value greater than this.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
-
- Participant
- Posts: 14
- Joined: Thu Jun 09, 2011 7:24 pm
- Location: USA
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
-
- Participant
- Posts: 14
- Joined: Thu Jun 09, 2011 7:24 pm
- Location: USA
not provided any thing(any field which has update time stamp/system gen time stamp) to identify new rows...there is unique key... looks like i have to fetch everything from source every time ..but still looking for alternatives
i tried left joining source with target but even it also do the same(fetching all data and looking up on target)
i tried left joining source with target but even it also do the same(fetching all data and looking up on target)
ram
-
- Participant
- Posts: 14
- Joined: Thu Jun 09, 2011 7:24 pm
- Location: USA
Two questions:
1) Is fetching the delta relevant for your process?
You have been talking about a hundred rows in your first post. For something below a hundred thousand rows I would not consider the issue relevant, because Change-Captured is going to identify changes in almost no time at all.
2) Is the only kind of change possible an insert of new key-values, or is it possible that data-rows for known keys change content on non-key-columns? In the latter case you have to fetch all rows from your source anyway.
1) Is fetching the delta relevant for your process?
You have been talking about a hundred rows in your first post. For something below a hundred thousand rows I would not consider the issue relevant, because Change-Captured is going to identify changes in almost no time at all.
2) Is the only kind of change possible an insert of new key-values, or is it possible that data-rows for known keys change content on non-key-columns? In the latter case you have to fetch all rows from your source anyway.
"It is not the lucky ones are grateful.
There are the grateful those are happy." Francis Bacon
There are the grateful those are happy." Francis Bacon
-
- Participant
- Posts: 14
- Joined: Thu Jun 09, 2011 7:24 pm
- Location: USA
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Depending on the version of SQL server you have , Change tracking can be enabled at the database level . Once you have done that . I think its an easy task to get only newly modified records( Adds/Updates)
Here is a good link for
Change Tracking in SQL Server 2008
Here is a good link for
Change Tracking in SQL Server 2008