I have to load a .csv file with different record format in to Oracle Table.
Each data block should contain one header record and zero to many detail records.
Eg:
A,1,3,date,time
B,1,date,time,seq No,transaction made
B,2,date,time,seq No,transaction made
B,3,date,time,seq No,transaction made
Here 1st record starting with A is the header record which has 3 detail records(starting with B).
Header record has 7 columns and detail record has 12 columns.
What stage should I use as input to load this .csv file in the oracle table.
Sequential file data(.csv) file with different record format
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 21
- Joined: Tue Apr 24, 2007 12:39 am
Sequential file data(.csv) file with different record format
Shadab Farooque
Re: Sequential file data(.csv) file with different record fo
if you are well aware of how many columns are their for your parent and child records, just like 7 columns for parent records and 12 fields for child.
then you can use sequential file stage to read your .CSV file and putting constraints in transformer stage you can Segregate out your parent and child record.
then you can use sequential file stage to read your .CSV file and putting constraints in transformer stage you can Segregate out your parent and child record.
Re: Sequential file data(.csv) file with different record fo
if you are well aware of how many columns are their for your parent and child records, just like 7 columns for parent records and 12 fields for child.
then you can use sequential file stage to read your .CSV file and putting constraints in transformer stage you can Segregate out your parent and child record.
then you can use sequential file stage to read your .CSV file and putting constraints in transformer stage you can Segregate out your parent and child record.
Re: Sequential file data(.csv) file with different record fo
if you are well aware of how many columns are their for your parent and child records, just like 7 columns for parent records and 12 fields for child.
then you can use sequential file stage to read your .CSV file and putting constraints in transformer stage you can Segregate out your parent and child record.
then you can use sequential file stage to read your .CSV file and putting constraints in transformer stage you can Segregate out your parent and child record.
-
- Participant
- Posts: 612
- Joined: Thu May 03, 2007 4:59 am
- Location: Melbourne
CFF stage?
Joshy George
<a href="http://www.linkedin.com/in/joshygeorge1" ><img src="http://www.linkedin.com/img/webpromo/bt ... _80x15.gif" width="80" height="15" border="0"></a>
<a href="http://www.linkedin.com/in/joshygeorge1" ><img src="http://www.linkedin.com/img/webpromo/bt ... _80x15.gif" width="80" height="15" border="0"></a>
Re: Sequential file data(.csv) file with different record fo
hello ray i am extremely sorry for my multiple posts, some problem with sessions.
How do you want to load it - only header? header and detail both? or only detail?
In any case, you can use the Sequential Stage and choose the Stage uses filter command option to specify a filter command (using grep command) to read either the header or the detail.
If you want both header and detail - then it makes more sense to read the entire data (header and detail both) in to a transformer and then split these into Header stream and Detail stream (depending on how you want) by using constraints - as suggested above.
Aneesh
In any case, you can use the Sequential Stage and choose the Stage uses filter command option to specify a filter command (using grep command) to read either the header or the detail.
If you want both header and detail - then it makes more sense to read the entire data (header and detail both) in to a transformer and then split these into Header stream and Detail stream (depending on how you want) by using constraints - as suggested above.
Aneesh