Import Accounts and Account Hierarchies Using the Account Import Macro

Here's how you populate the account import macro with your data and import. You can enter and import a maximum of 5,000 records at a time. You must wait until a previous import is complete before using the macro again.

Note: You can modify the macro to import additional fields, including any custom fields you created, using the Attributes Mapping worksheet in the macro.
  1. Open the Account Import Macro.

  2. If you receive a security warning that macros have been disabled, you must enable macros.

  3. Click the Resource EMail to ID Mapping worksheet.

  4. Click Populate Resource Attributes from Server to populate the worksheet with information about the resources who are the owners of the accounts you're importing.

    The Login window appears.

  5. In the Login window, do the following:

    1. Enter the host name. The host name is in the portion of the URL between https:// and /sales.

    2. Enter the user name and password.

    3. Click Submit.

  6. If you're importing additional fields, including custom fields, then do the following:

    1. Click the Attributes Mapping worksheet.

    2. Click Fetch Attributes from Server.

    3. In an empty row in the worksheet, select the attribute from the Attribute Name column.

    4. Enter the name you want displayed as the column heading in the Account worksheet. This name displays only in the macro.

    5. Click Update Headers to add the column to the Account worksheet.

  7. Click the Account worksheet, and enter the account data in the columns.

    The address you enter in the worksheet becomes the primary address for the account. If you create sales territories by address, the assignment process uses the primary address to assign territories.


    What to Enter

    Account Number

    Required unique ID for the organization. You can leave this field blank and generate the IDs later by clicking Generate Account Number.

    Account Name

    The name of the organization. Entry in this column is required.

    D-U-N-S number

    The data universal numbering system (D-U-N-S) number from Dun & Bradstreet Corporation.

    Account Type

    Enter either ZCA_CUSTOMER or ZCA_PROSPECT.

    • ZCA_CUSTOMER for organizations you have sold to in the past.

    • ZCA_PROSPECT for potential customers. If an organization still requires qualification, then you should consider importing the record as a lead instead.

    If you leave this column blank, then the macro enters ZCA_PROSPECT.

    Owner E-Mail

    Enter the email address of the salesperson who is the account owner. The email address must be listed on the Resource EMail to ID Mapping worksheet. Entry in this column is required.

    Address Number

    A unique identifier for the address. If you leave this column blank, then the macro generates the number for you when you import.

    If you want to reuse an address from another account, then you can enter the address number from that address and skip the rest of the address fields.

    Address 1

    Enter the street address for the primary account address.

    Address 2

    Enter additional address information, such as the suite number.




    For the US, enter one of the two-letter state codes.

    Postal Code

    Postal code.

    Country Code

    The two-letter ISO code for a country. For example, enter US for the United States, and IN for India. Entry is required.

    Address Type

    Address types indicate how an address is used. For example, a customer gets billed at the bill-to address and receives the goods at the ship-to address. Address types are displayed only if you enable the display of multiple addresses for accounts.

    You can import any of the address type codes entered in the lookup type Party Site Use Code (PARTY_SITE_USE_CODE) with the tag SALES_CLOUD. By default, these are the codes available for import:

    • BILL_TO

    • SELL_TO

    • SHIP_TO

    The sales application by itself doesn't use the address type to drive any logic, but different applications you integrate may. By default, every account address you create in the application is set to the sell-to address.

    Phone Country Code

    Country code for the main phone for the organization.

    Phone Number

    Main phone number. No spaces or delimiters.

    Fax Country Code

    Fax number country code.

    Fax Number

    Fax number. No spaces or delimiters.


    Email address.


    The URL.

    Industry Code

    The industry code that you retrieved from the application for the classification category that you're using. You can obtain a list of the codes using the Manage Classification Categories task as described in the Viewing Classification Categories for Accounts topic.

    Named Flag

    A Y entry indicates the account is a named account. You can create special assignment for named accounts.

    Parent Account Number

    Enter the account number of a parent account to create an account hierarchy. You can copy over the IDs from the Account Number column.

  8. In the account import macro, click Create Import Activity.

    The Login window is already populated with the information you provided earlier.

  9. Click Submit.

  10. Here's what to do if you're prompted to correct errors in your entries:

    1. Click OK

      The Error worksheet displays your errors.

    2. Click each error link in column D and make the correction on the Account worksheet.

      Note: After you correct an error, you must click outside the field for the correction to be recognized.
    3. Click Create Import Activity and Submit again.

  11. If the macro data is validated without errors, then the macro displays one of the following messages.



    The file import activity was submitted successfully.

    Your import has started. If the file import activity is submitted successfully, then the confirmation message displays the job ID.

    Unable to connect to the server at this time.

    You may have entered an incorrect host.

    Unable to submit the file import activity. Check log for details.

    Open the Errors work sheet to view the error details.

  12. If your import activity was submitted successfully, then click Activity Details.

    The Activity Details window lists the import activity name, ID, and its status.

    • If the import activity is still in progress, you can refresh the status periodically by clicking Refresh.

    • A status of "Completed" means your import completed successfully.