If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > MySQL > Need to Insert Records in target table.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 11-09-11, 06:04
SureshRam SureshRam is offline
Registered User
 
Join Date: Nov 2011
Posts: 1
Need to Insert Records in target table.

Hi All,

This is my first thread in this forum.

My source table name is Emp and Target table name is Emp_Org.

Given below is the structure of the source table

Empno(p.key) deptno(p.key) empname currenttimestamp

Target Table MetaData.

Empno(p.key) country Emporg currenttimestamp Targettimestamp

My problem is In my source table I have 10000 records. While I run the job(ETL),out of 10000 records only 4000 records are Inserted into the target table. If I run the job again, I need to run the job from 4001 onwards not from the begining.

I have made the design in my job(ETL.datastage). But architect he wants that I need to execute this logic in sql.

I don't have idea how to do this?. Any help would be really appreciated.

Last edited by SureshRam; 11-09-11 at 06:36.
Reply With Quote
  #2 (permalink)  
Old 11-09-11, 06:42
r937 r937 is offline
SQL Consultant
 
Join Date: Apr 2002
Location: Toronto, Canada
Posts: 19,525
Quote:
Originally Posted by SureshRam View Post
While I run the job(ETL),out of 10000 records only 4000 records are Inserted into the target table.
sounds like this is the problem right here

fix your ETL job
__________________
r937.com | rudy.ca
please visit Simply SQL and buy my book
Reply With Quote
  #3 (permalink)  
Old 11-09-11, 10:07
it-iss.com it-iss.com is offline
Registered User
 
Join Date: Sep 2009
Location: San Sebastian, Spain
Posts: 620
Hi,

how are you loading the data into the table? Are you using LOAD INTO? If yes, then have a look at the IGNORE number LINES option but as Rudy has said you should focus your efforts on fixing the ETL job.
__________________
Ronan Cashell
Senior Oracle/MySQL DBA
http://www.it-iss.com
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On