Table of Contents

Search

PowerExchange for PostgreSQL User Guide for PowerCenter

PowerExchange for PostgreSQL User Guide for PowerCenter

PostgreSQL Mapping Example

PostgreSQL Mapping Example

You work for an organization that stores purchase order details, such as customer ID, item codes, and item quantity in a Microsoft SQL Server. You need to analyze purchase order details and move data from the Microsoft SQL Server database to PostgreSQL.
Create a mapping to read all the purchase records from Microsoft SQL Server, process the data, and write them to a PostgreSQL target.
Perform the following tasks to move data from Microsoft SQL Server to PostgreSQL:
  1. Import the Microsoft SQL Server source.
  2. Import a PostgreSQL target.
  3. Create a mapping with a Microsoft SQL Server source and a PostgreSQL target.
    The following image shows the example mapping in the Mapping Designer:
    The mapping example shows a relational source, a source qualifier, and a PostgreSQL target.
  4. Create a session and configure the session properties to load the data to the PostgreSQL target.
    The mapping contains the following objects:
    Source Definition
    The mapping source definition is a relational database object. In the
    Source Analyzer
    , import the Microsoft SQL Server source. The PowerCenter Integration Service reads the customer transaction details from the Microsoft SQL Server source.
    The following table describes the structure of the source definition called CUSTOMER:
    Field
    Data Type
    CUSTOMER_ID
    Varchar
    CUSTOMER_NAME
    Varchar
    ITEM_PURCHASED
    Varchar
    PRICE
    Float
    Mapping Target
    The mapping contains a PostgreSQL target definition.
    In the
    Target Designer
    , import a PostgreSQL target definition.
    The following table describes the structure of the target definition called SCDW_CUSTOMER:
    Field
    Data Type
    CUSTOMER_ID
    Varchar
    CUSTOMER_NAME
    Varchar
    ITEM_PURCHASED
    Varchar
    PRICE
    Double

0 COMMENTS

We’d like to hear from you!