Getting Started with Informatica Intelligent Cloud Services on Google Cloud Platform

Getting Started with Informatica Intelligent Cloud Services on Google Cloud Platform

Step 5. Create a mapping to load a CSV file into Google BigQuery

Step 5. Create a mapping to load a CSV file into Google BigQuery

In this step, you load a CSV file from the flat file directory configured in flat file connection and write it to a table created during runtime in Google BigQuery. Use the same CSV file that you used in the previous step.
  1. In
    Data Integration
    , click
    New
    to open the
    New Asset
    dialog box.
  2. In the
    New Asset
    dialog box, click
    Mappings
    in the menu on the left, select
    Mapping
    , and click
    Create
    .
  3. When the mapping opens, enter the mapping name in the
    Name
    field:
    When you create a mapping, the Mapping Designer displays a new mapping with a Source and Target transformation. The mapping properties appear below the canvas. The Name field is the topmost property.
  4. Click the Source transformation in the canvas.
  5. On the
    General
    tab, update the name of the Source transformation to reflect the actual object.
    In this case, the source is a CSV file.
  6. Click the
    Source
    tab, and perform the following steps:
    1. In the
      Connection
      field, select the flat file connection that you created.
    2. Click
      Select
      next to the
      Object
      field to select the CSV file.
      IICS treats flat files as CSV by default. You can change the formatting by clicking
      Formatting Options
      .
    3. Optionally, click
      Preview Data
      if you want to view the first few rows of the data file.
    The Source tab of the Source transformation displays source details such as the connection, source type, and source object. In this image, the connection is a flat file connection, the source type is a single object, and the source object is the CSV file.
  7. Click the Target transformation in the canvas.
  8. On the
    General
    tab, update the name of the Target transformation to reflect the actual object.
    In this case, the target is Google BigQuery.
  9. Click the
    Target
    tab, and perform the following steps:
    1. In the
      Connection
      field, select the Google BigQuery V2 connection that you created.
    2. Click
      Select
      next to the
      Object
      field to create the target file.
    3. Select
      Create New at Runtime
      .
    4. In the
      Object Name
      field, enter the name of the target file that will be created.
    5. In the
      Path
      field, enter the name of the Google BigQuery dataset where the table will be created:
      In the Target Object dialog box, the target object is set to "Create New at Runtime." The object name is the name of the target file to be created, and the path is the Google BigQuery dataset where the target table will be created.
      For information about creating Google BigQuery datasets, see this GCP guide.
  10. Click
    Save
    .
  11. Click the
    Field Mapping
    tab.
    When you create a new target object, IICS automatically creates and maps fields from incoming fields, which come from the source dataset in this case, to the target:
    The target Field Mapping tab lists incoming fields on the left. The Target Fields list on the right indicates whether and how each target field is mapped to an incoming field. In this image, each target field is mapped to an incoming field with the same name.
  12. Click
    Run
    in the top right corner of the screen:
    The Run button appears in the top right corner of the Mapping Designer next to the Save button.
  13. Select the runtime environment, and then click
    Run
    :
    When you run the mapping, the Run dialog box appears. The Runtime Environment field appears at the top of the dialog box. The Run button appears in the bottom right corner between the Next and Cancel buttons.
  14. Click
    My Jobs
    to open the job activity page:
    The My Jobs page shows the jobs that you have run and the location, start time, end time, rows processed, and status for each job. In this image, the CSV to Google BigQuery mapping is the only job displayed. Its status indicates that the job completed successfully.
The target table is created in the Google BigQuery dataset:
The Google BigQuery dataset details show that the new target table has been created.

0 COMMENTS

We’d like to hear from you!