FLAT FILE LOAD
Import Flat File Source Definition:
4. Browse the File path and select the File.
Import Flat File Target Definition:
1. Select Tools --> Target Designer
2. Select Target from Menu --> 'Import from File' and follow step from 4 to 8.
INDIRECT LOAD
A file list is nothing but loading multiple source files of same structure using one instance in the mapping. If an organization collects data at several locations which you then want to move through the same session. We need to create a mapping to use multiple source files for one source instance.
Import Flat File Source Definition:
1. Connect and Open the folder where you want to import flat file definition. If it not exist in the folder.
2. Select Tools --> Source Analyser
3. Click on Source Menu --> Import from File
4. It will ask you File Path
Note: Change Files of types: All Files (*.*) to see all types of files.
5. Click 'OK'.
6. Flat File Import Wizard - Step 1 of 3 will appears.
- Choose the Flat File Type is eitherDelimited or Fixed Width.
- Enter a name for this source: EMPLOYEE
- Start Import at Row: 2. If you specify to start at row 2, the Flat File Wizard skips 1 row before reading.
- Select 'Import field names from first line', If you want to import the port name from the 1st row of the flat file.
- Click 'Next'
- Select the Delimited: Comma (in my case). You can choose Tab, Semicolon, Comma, Space, Other (Character used to separate columns of data).
- Treat Consecutive Delimiters as One: If selected, the Flat File Wizard reads one or more consecutive column delimiters as one. Otherwise, the Flat File Wizard reads two consecutive delimiters as a null value.
- Treat Multiple Delimiters as AND: If selected, the Flat File Wizard reads a specified set of delimiters as one.
- Escape Character: Character immediately preceding a column delimiter character embedded in an unquoted string, or immediately preceding the quote character in a quoted string. When you specify an escape character, the Integration Service reads the delimiter character as a regular character. This is called escapingthe delimiter or quote character.
- Remove Escape Character From Data: This option is selected by default. Clear this option to include the escape character in the output string.
- Use Default Text Length: If selected, the Flat File Wizard uses the entered default text length for all string datatypes.
- Text Qualifier: Quote character that defines the boundaries of text strings. Choose No Quote, Single Quote, or Double Quotes. If you select a quote character, the Flat File Wizard ignores delimiters within pairs of quotes.
- Click 'Next'.
Note: Treat Consecutive Delimiters as One, Treat Multiple Delimiters as AND, Escape Character are optional.
8. Flat File Import Wizard - Step 3 of 3 will appears.
- Name: Port name that you want to appear for each column. If you select Import Field Names from First Line, the wizard reads the column names provided in the file instead.
- Datatype:Column datatype. Select Text, Numeric, or Datetime, and then enter the appropriate Length/Precision, Scale, and Width.
- For numeric columns, Precision is the number of significant digits. The Flat File Wizard ignores the width for numeric columns in delimited files.
- For Text columns, Precision is the maximum number of characters contained in the source field or the target field. The Flat File Wizard ignores the precision when reading text columns in or writing text columns to delimited files.
- By default, the Flat File Wizard enters the same value for both Precision and Width. You can change the value of the precision or width, but the Flat File Wizard only lets you define the precision to be greater than or equal to the width.
- Click 'Finish'
Import Flat File Target Definition:
1. Select Tools --> Target Designer
2. Select Target from Menu --> 'Import from File' and follow step from 4 to 8.
INDIRECT LOAD
A file list is nothing but loading multiple source files of same structure using one instance in the mapping. If an organization collects data at several locations which you then want to move through the same session. We need to create a mapping to use multiple source files for one source instance.
To use multiple source files, you create a file containing the names and directories of each source file you want the Integration Service to use. This file is referred to as a file list.
When we configure the session properties, enter the file name of the file list in the Source Filename field, enter the location of the file list in the Source File Directory field and Source filetype as Indirect. When the session starts, the Integration Service reads the file list, then locates and reads the first file source in the list. After the Integration Service reads the first file, it locates and reads the next file in the list.
The Integration Service writes the path and name of the file list to the session log. If the Integration Service encounters an error while accessing a source file, it logs the error in the session log and stops the session.
Note: When you use a file list and the session performs incremental aggregation, the Integration Service performs incremental aggregation across all listed source files.
Creating the File List
The file list contains the names of all the source files you want the Integration Service to use for the source instance in the session. Create the file list in an editor appropriate to the Integration Service platform and save it as a text file.
Use the following rules and guidelines when you create the file list:
- Each file in the list must use the user-defined code page configured in the source definition.
- Each file in the file list must share the same file properties as configured in the source definition or as entered for the source instance in the session property sheet.
- Enter one file name or one path and file name on a line. If you do not specify a path for a file, the Integration Service assumes the file is in the same directory as the file list.
- Each path must be local to the Integration Service node.
Example shows a valid file list created for an Integration Service on Windows
C:\Informatica\SourceFileDir\department_list.dat
d:\data\department_10.dat
e:\data\department_20.dat
f:\data\department_30.dat
After you create the file list, place it in a directory local to the Integration Service
Configuring a Session to Use a File List
Once you create a file list for multiple source files, you can configure the session to access those files.
1. Open the session properties.
2. Click the Mapping tab and open the Transformations view.
3. Click the Properties settings in the Sources node.
4. In the Source Filetype field, choose 'Indirect'.
5. In the Source Filename field, replace the file name with the name of the file list.
6. Click Apply and OK.





































































































