> ## Documentation Index
> Fetch the complete documentation index at: https://www.integrate.io/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# ETL: NetSuite Source

> Use the NetSuite source component to read NetSuite standard and custom records (tables) using the NetSuite JDBC drivers (SuiteAnalytics Connect).

## Connection Setup: NetSuite

## To create a NetSuite JDBC(Source) connection in Integrate.io ETL

<Steps>
  <Step>
    Click the Connections icon (lightning bolt) on the top left menu.
  </Step>

  <Step>
    To create a connection, click **New connection**.

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-45.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=44272da9d72aaf84241f141f09a490ed" alt="Connections page with New connection button" width="1200" height="829" data-path="images/connectivity-and-security/image-45.webp" />
    </Frame>
  </Step>

  <Step>
    Select **NetSuite JDBC(Source)**.

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-46.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=6044fca42cc6bf41ef02b9a0009e7282" alt="Selecting NetSuite JDBC Source from the connection type list" width="1200" height="829" data-path="images/connectivity-and-security/image-46.webp" />
    </Frame>
  </Step>

  <Step>
    In the new NetSuite JDBC(Source) connection window, name the connection and enter the connection information.

    * **Name** - name for the new connection
    * **Hostname** - copy from SuiteAnalytics Connect configuration (see image below)
    * **Port** - copy from SuiteAnalytics Connect configuration (see image below)
    * **User name** - your NetSuite user name.
    * **Password** - your NetSuite password.
    * **Service data source** - copy from SuiteAnalytics Connect configuration (see image below).
    * **Account ID** - copy from SuiteAnalytics Connect configuration (see image below).
    * **Role ID** - copy from SuiteAnalytics Connect configuration (see image below).
  </Step>

  <Step>
    Then, test the NetSuite connection by clicking **Test connection**. Once the connection tests successful, click **Create connection**.

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-47.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=49b4331863005b9d59ccc50d500955e7" alt="NetSuite JDBC connection form with hostname, port, and credentials" width="1200" height="829" data-path="images/connectivity-and-security/image-47.webp" />
    </Frame>

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-48.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=177ae83b0eb36493cbaec635e5602eda" alt="NetSuite JDBC connection test and Create connection button" width="1200" height="829" data-path="images/connectivity-and-security/image-48.webp" />
    </Frame>
  </Step>
</Steps>

You can find the connection information needed above in the SuiteAnalytics Connect configuration panel shown here:

<Frame>
  <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-49.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=a87d3d4abc2ac6621551ab50003fe258" alt="SuiteAnalytics Connect configuration panel with connection details" width="2772" height="1142" data-path="images/connectivity-and-security/image-49.webp" />
</Frame>

## To setup Netsuite2.com as data source

<Steps>
  <Step>
    Create a new role. Go to **Setup** > **Users/Roles** > **Manage Roles** > **New**.

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-50.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=374f66584b0e82e61a594ca2e8d9ad28" alt="Creating a new role in NetSuite Setup" width="3340" height="1872" data-path="images/connectivity-and-security/image-50.webp" />
    </Frame>
  </Step>

  <Step>
    Enter a name for this role. Select **Permissions** tab and then click **Setup** tab and assign following permissions:

    * Log in using Access Tokens
    * SuiteAnalytics Connect

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-51.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=f94f3be13ff99f6ff6ab3ed5d5fc49fe" alt="Assigning SuiteAnalytics Connect permission to the role" width="3334" height="1930" data-path="images/connectivity-and-security/image-51.webp" />
    </Frame>

    <Note>
      **Note:**

      The 'Subsidiary Restriction' section may limit access to certain records you wish to retrieve. Depending on the type of subsidiary structure your organization operates under, you should carefully select these options to ensure you obtain the desired data.
    </Note>

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-52.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=798b2fd988afb837321be79d98055f92" alt="Subsidiary restriction options on the role configuration" width="1200" height="613" data-path="images/connectivity-and-security/image-52.webp" />
    </Frame>
  </Step>

  <Step>
    Grant an access to the selected tables. On the same role creation page, go to **Lists** tab and select tables.

    <Note>
      **Note:**

      The screenshot below is demonstrating how to enable access to the Account table. Before proceeding, we recommend coordinating with your business team to determine the complete list of NetSuite tables required for your integration. Once the list is finalized, please contact your NetSuite Account Manager for assistance in configuring the appropriate permissions to ensure all relevant tables are both visible and accessible for integration purposes.
    </Note>

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-53.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=49f6e932164cb3e6c4eff7dee038e6b9" alt="Granting table access permissions in the Lists tab" width="3344" height="1928" data-path="images/connectivity-and-security/image-53.webp" />
    </Frame>
  </Step>

  <Step>
    Assign the Roles to the selected User. Select **Access** tab and then add following roles under **Roles** tab:

    * The role that has just been created from previous step
    * **Data Warehouse Integrator** role

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-54.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=777a56a9c49dd92a2a3d1c15df624b43" alt="Assigning roles to a user in the Access tab" width="3364" height="1862" data-path="images/connectivity-and-security/image-54.webp" />
    </Frame>
  </Step>

  <Step>
    Configure DB connection in Integrate.io ETL. Enter connection information (see steps "To create a Netsuite connection in Integrate.io ETL" from above) along with **Netsuite2.com** as Service data source and Role ID from the role that we just created from step 2.

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-55.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=9dcfe14d90f371db9662a36ae5611619" alt="Connection form with Netsuite2.com as service data source" width="1822" height="1940" data-path="images/connectivity-and-security/image-55.webp" />
    </Frame>
  </Step>
</Steps>

## Connection Setup: NetSuite (SOAP)

## Setting up on NetSuite dashboard

To enable SOAP Web Services and Token Based Authentication, you need to login to your Netsuite dashboard with admin roles and please follow these steps:

<Steps>
  <Step>
    Go to Setup > Company > Enable Features > SuiteTalk (Web Services) and enable both "SOAP Web Services" and "Token-based Authentication".

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-56.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=7f79107373bc2aed2b333d54151d3701" alt="Enabling SOAP Web Services and Token-based Authentication" width="3518" height="1826" data-path="images/connectivity-and-security/image-56.webp" />
    </Frame>
  </Step>

  <Step>
    Create a new Integration. Navigate to Setup > Integrations > Manage Integrations > New. Please note that "Token-based Authentication" must be checked.

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-57.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=dafac18be51f40e12ded83f1cdd0bc72" alt="Creating a new integration with Token-based Authentication checked" width="3522" height="1804" data-path="images/connectivity-and-security/image-57.webp" />
    </Frame>
  </Step>

  <Step>
    After finished creation integration, save the Consumer Key and Consumer Secret as it will be only shown once and used for connection configuration on Integrate.io ETL.

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-58.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=cad0645fbb4c618e3fed472b675f7c74" alt="Consumer Key and Consumer Secret displayed after integration creation" width="1588" height="1664" data-path="images/connectivity-and-security/image-58.webp" />
    </Frame>
  </Step>

  <Step>
    Create a new role. Go to Setup > User Management > Manage Roles > New. Check "Web Services Only Roles" and add following permissions on Permissions > Setup tab:

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-59.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=3d9484a7be4e1c0453f7740797293d85" alt="Role creation with Web Services Only Roles and permissions" width="3506" height="1838" data-path="images/connectivity-and-security/image-59.webp" />
    </Frame>

    * SOAP Web Services
    * Log in using Access Tokens
    * Custom Body Fields
    * Custom Item Fields
    * Custom Fields

    <Note>
      **Note:**

      The 'Subsidiary Restriction' section may limit access to certain records you wish to retrieve. Depending on the type of subsidiary structure your organization operates under, you should carefully select these options to ensure you obtain the desired data.
    </Note>

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-60.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=2ac98eabdb0e6be0090de365215a1c35" alt="Subsidiary restriction settings on the SOAP role" width="1200" height="613" data-path="images/connectivity-and-security/image-60.webp" />
    </Frame>

    1. Assign the role from previous step to existing or a new user. Navigate to Setup > User Management > Manage Users.
           <Frame>
             <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-61.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=2a7f19590f02844e40b9814ff9f59128" alt="Assigning the SOAP role to a user in Manage Users" width="3582" height="1550" data-path="images/connectivity-and-security/image-61.webp" />
           </Frame>
    2. Create a new access token. Go to Setup > User Management > Access Tokens. Select the name of Integration, User and Role from previous steps. After saving it, Token ID and Token Secret will be shown and keep those values securely.
           <Frame>
             <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-62.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=f73f2173aaeb7a1a61b9dc35f80c2128" alt="Creating a new access token with Token ID and Token Secret" width="1790" height="1242" data-path="images/connectivity-and-security/image-62.webp" />
           </Frame>
  </Step>
</Steps>

## To create a NetSuite SOAP connection in Integrate.io ETL

<Steps>
  <Step>
    Click the Connections icon (lightning bolt) on the top left menu.
  </Step>

  <Step>
    To create a connection, click **New connection**.

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-63.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=d95c6220368def294e0b5b7783324aa7" alt="Connections page with New connection button for SOAP" width="1200" height="829" data-path="images/connectivity-and-security/image-63.webp" />
    </Frame>
  </Step>

  <Step>
    Select **NetSuite SOAP**.

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-64.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=af8f64b264d87ee3e89138ef499b9c74" alt="Selecting NetSuite SOAP from the connection type list" width="1200" height="829" data-path="images/connectivity-and-security/image-64.webp" />
    </Frame>
  </Step>

  <Step>
    In the new NetSuite connection window, name the connection and enter the connection information.

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-65.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=867a33f481be5e75724cac45a80b1153" alt="NetSuite SOAP connection form with Account ID and token fields" width="1200" height="829" data-path="images/connectivity-and-security/image-65.webp" />
    </Frame>

    * **Name** - name for the new connection
    * **Account ID** - need to include the suffix `_SB<number>` for Sandbox account.
    * **Consumer Key** - copy from previous step or SuiteAnalytics Connect configuration.
    * **Consumer Secret** - copy from previous step or SuiteAnalytics Connect configuration.
    * **Token ID** - copy from previous step or SuiteAnalytics Connect configuration.
    * **Token Secret Account ID** - copy from previous step or SuiteAnalytics Connect configuration.
  </Step>

  <Step>
    Then, test the NetSuite connection by clicking **Test connection.** Once the connection tests successful, click **Create connection.**

    <Frame>
      <img src="https://mintcdn.com/integrateio/K1OxIkBgHF64pvnH/images/connectivity-and-security/image-66.webp?fit=max&auto=format&n=K1OxIkBgHF64pvnH&q=85&s=e0eeac5bcdd61182b87ca97d613d4319" alt="NetSuite SOAP connection test and Create connection button" width="1200" height="829" data-path="images/connectivity-and-security/image-66.webp" />
    </Frame>
  </Step>
</Steps>

***

<Frame>
  <img src="https://mintcdn.com/integrateio/OwEKdS5aIKsEcmhX/images/creating-packages/using-components-netsuite-source/image-1.png?fit=max&auto=format&n=OwEKdS5aIKsEcmhX&q=85&s=af770a17b06ca2595e03e8dda85a1206" alt="NetSuite source component in the pipeline designer" width="1200" height="828" data-path="images/creating-packages/using-components-netsuite-source/image-1.png" />
</Frame>

## Connection

Select an existing NetSuite connection or create a new one (for more information, see [Allowing Integrate.io ETL access to NetSuite](/etl/allowing-integrateio-etl-access-to-netsuite).)

## Source Properties

<Frame>
  <img src="https://mintcdn.com/integrateio/OwEKdS5aIKsEcmhX/images/creating-packages/using-components-netsuite-source/image-2.png?fit=max&auto=format&n=OwEKdS5aIKsEcmhX&q=85&s=5a16d51b18cd6c289c2b0ab4e2e30ce3" alt="NetSuite source properties with table and where clause fields" width="1200" height="828" data-path="images/creating-packages/using-components-netsuite-source/image-2.png" />
</Frame>

* **Source table** - the table name from which the data will be imported. Use the [Suitetalk Connect schema browser](https://www.netsuite.com/portal/developers/resources/suitetalk-documentation.shtml "Link: https://www.netsuite.com/portal/developers/resources/suitetalk-documentation.shtml") to look up standard records and columns.
* **where clause** - optional. You can add predicates clauses to the WHERE clause as part of the SQL query that is built in order to get the data from the database. Make sure to skip the keyword WHERE.
  | Good                                                                                                                          | `prod_category = 1 AND prod_color = 'red'`       |
  | :---------------------------------------------------------------------------------------------------------------------------- | :----------------------------------------------- |
  | Bad                                                                                                                           | `WHERE prod_category = 1 AND prod_color = 'red'` |
  | **Notes:** in NetSuite2, the table names for entities such as customers, items, and contacts are singular rather than plural. |                                                  |

## Source Schema

After defining the source table/query select the fields to use in the source.

The fields you select are used to build the query that will be executed to read the data.

Define the data type for the field. Use the following table when matching NetSuite data types to Integrate.io ETL data types.

| NetSuite  | Integrate.io ETL |
| :-------- | :--------------- |
| varchar2  | String           |
| number    | Double           |
| timestamp | Datetime         |
