Sequential File Stage in Datastage?

SEQUENCIAL FILE STAGE:

It is a file stage which is used to extract data from flat files (.txt, csv, .xls) and It supports one input link and one output link and one reject link and It is used either in source (or) target to extract data from flat files and Sequential file stage process the data sequentially by default ,In Sequential file stage Read Methods are two types

Read Method = Specific files

= File pattern

Example of specific files:

c:\emp.txt

Example of file pattern:

C:\emp1.txt

C:\emp2.txt

C:\emp3.txt

If the file path is like above then if we want o extract data from all above files then we can specify like this

C:\emp*.txt à* for one or more character matching

C:\emp? .txtà? For single character matching

 

LIMITAIONS OF SEQUENCIAL FILE:

It supports up to 2 GB Of data

EXAMPLE JOBS FOR SEQUENTIAL FILE STAGE:

Requirement: Extracting EMP data from text file and loading into text file By using Sequential file Stage

Here Read method= specific file(s)

Input File data:

SF1

Output File data:

SF2

Job:

SF3

Properties for sequential_File_0:

SF4.jpg

Target Sequential_File_1 Properties:

SF5

Importing A table definition from sequential file:

Right click on sequential_file_0 Or double click on seqential_file_0

SF1

SF2

Click on Columns tab on left hand side tab

SF3

Click on Load Tab at Bottom

It will show the Window like this

SF4

Now Click On import and select Sequential file definitions

SF5

Now in the file list u select the file emp1.txt

SF6

Click on Import tab:

SF7

Tick the check box First line is column names and Click on Defines

SF8

Now Click on Ok and click on Close tab Now that file emp1.txt will show in the table Definition list

SF9

Now Select Emp1.txt in table definition list and click on OK

SF10

It will show Window like this

SF11

Now Click on OK and again Click on OK ….This is the way of procedure for importing table definition

 

 

Related Posts Plugin for WordPress, Blogger...

Be the first to comment

Leave a Reply

Your email address will not be published.


*