Learning Informatica PowerCenter 10.x(Second Edition)
上QQ阅读APP看书,第一时间看更新

Working with Sources - the Create option

Apart from importing the file or table structure, we can manually create the Source Definition. When the sample source file or the table structure is not available, we need to manually create the source structure. When we select the create option, we need to define every details related to the file or table manually, such as the name of the source, type of source, column names, column data type, column data size, indexes, constraints, and so on. When you import the structure, the import wizard automatically imports all these details.

Following are the steps that you will have to perform to create option.

  1. In the Designer, go to Tools | Source Analyzer to open the Source Analyzer.
  2. Go to Sources | Create:
  1. Mention the name of the Source as per your requirement, and select the type of Source you wish to create from the drop-down list. For our reference, we are using Flat File as our source type and SRC_STUDENT as the source file name.
  2. Also, select the Database type for the new source to be created. Since we wish to create a Flat File, we have selected Flat File as shown in the following screenshot:
  1. Click on Create and then on Done.
  2. An empty source structure with the name SRC_STUDENT will appear in the Source Analyzer as shown in the following screenshot:
  1. Since we are using the create option, we need to manually specify all the details such as the column names, data type, precision, and so on.
  2. Double-click on the title bar of SRC_STUDENT to open the source definition.
  3. The Edit Tables dialog box appears and displays all the properties of this source definition. The Table tab shows the name of the table, the name of the owner, and the database type. You can add a comment in the description section. The Business name field is empty since we don't use it.
  1. Click on the Columns tab, which displays the column descriptions for the source. Here, we have options to add a new column, delete an existing column, and so on.
    • Add a new column: Click on this option to add a new column as shown in the previous screenshot. You can add multiple columns as per your requirement. Once you add a new column, specify the other details such as data type, precision, and so on for the column you added.
    • Delete a column: To delete a column, click on the column you wish to delete, and click on the delete button.
    • Copy an existing column: You can copy an existing column if you wish to make a column similar to an existing column.
    • Paste the copied column: You can paste the copied column as per requirement.
    • Move up or down the column to rearrange the columns inside the source definition.

We have added few columns to the Source as can be seen in the following screenshot:

  1. Click on the Metadata Extensions tab. Metadata extensions allow you to extend the metadata stored in the repository by associating information with individual repository objects. For example, you can store contact information, such as name or e-mail address, with the sources you create. This is an option and usually left empty.

 

 

  1. Click on Apply and then on OK to close the dialog box to get the source definition in the Source Analyzer:
  1. Go to Repository | Save or press Ctrl + S to save the changes to the repository.

We're done working with sources. Let's now move on to Targets!