How to Create Flat File Source Module and Import Flat File

In this post, you will learn how to create a flat file source module and import flat file. Source modules hold metadata describing source systems. Target modules hold metadata describing your target data warehouse.

Flat files are a typical data source for warehouse projects.

A flat file source module defines a connection to a folder that contains a number of sample records of flat files. You will also learn how to use the wizard to import flat file metadata into the flat file source module.

1.Creating a Flat File Source Module

Step 1: Right-click on Files folder under My_Project and select New Flat File Module to create a file module. On the next screen provide a name to your file module.

How to Create Flat File Source Module and Import Flat File

 

Step 2: Enter the Name and Description and click Next.

How to Create Flat File Source Module and Import Flat File

 by clicking the edit button in the above window. Follow all steps as given in screenshots to complete the process.

Step 3: To Edit File Location System click on the edit button.

How to Create Flat File Source Module and Import Flat FileProvide location information of source file in this module also by clicking the edit button in the above window. Follow all steps as given in screenshots to complete the process.

Step 4: Choose the Directory.

How to Create Flat File Source Module and Import Flat File

Step 5: After editing the file location it will shows the Path of the File.

How to Create Flat File Source Module and Import Flat File

Step 6: Summary screen shows the message Module definition is Complete and click on Finish.

How to Create Flat File Source Module and Import Flat File

 

2. Importing Flat File

Step 1: Right-click on the File and click on New option.

How to Create Flat File Source Module and Import Flat File

Step 2: Welcome screen will open just click on the Next.

How to Create Flat File Source Module and Import Flat File

Step 3: Enter the Name for the Flat files folder and click Next.

How to Create Flat File Source Module and Import Flat File

 

Step 4: Click on the Edit button and select the path for the .csv file.

How to Create Flat File Source Module and Import Flat File

Step 5: Summary screen will display you the information about the module definition is completed.

How to Create Flat File Source Module and Import Flat File

Step 6: Now you will see that the Flat file folder is created in File Node.

How to Create Flat File Source Module and Import Flat File

Step 7: Right-click on the Sales_Flat folder and select the import option to import the Flat file.

How to Create Flat File Source Module and Import Flat File

 

Step 8: Welcome screen displays the steps to import the flat file.

How to Create Flat File Source Module and Import Flat File

Step 9: Select the option Data files matching this pattern for the .csv file.

How to Create Flat File Source Module and Import Flat File

Step 10: Select the object to import into Sales_Flat module.

How to Create Flat File Source Module and Import Flat File

Step 11: Import the Countries Flat file into Sales_Flat module.

How to Create Flat File Source Module and Import Flat File

 

Step 12: This screen provides a Name and description of the flat file and here you have to click Next.

How to Create Flat File Source Module and Import Flat File

Step 13: Select option as Record Delimited by and select <CR> option and click Next.

How to Create Flat File Source Module and Import Flat File

Step 14: Select the File format and click Next.

How to Create Flat File Source Module and Import Flat File

Step 15: Specify the record type and click Next

How to Create Flat File Source Module and Import Flat File

Step 16: Checkmark on Use the first records as field names and click Next.

How to Create Flat File Source Module and Import Flat File

Step 17: Change the length of the field and click Next.

How to Create Flat File Source Module and Import Flat File

Step 18: Summary screen shows the message Module definition is Complete and click on Finish.How to Create Flat File Source Module and Import Flat File

Please let me know if this helped you and I’ll be happy to answer any of your questions in the comment section below! 

Leave a Reply