Salesforce

ExpandedToggleIcon        Connection Dialog

Excel Add-in for Salesforce supports two kinds of authentication: UserNamePassword and AccessRefreshToken.

 

Username and password authentication

 

To connect with username and password authentication you need to specify the following required parameters:

1.Host - The Salesforce.com or Database.com login URL.
2.User Id - The Salesforce login account.
3.Password - The password for the Salesforce login account.
4.Security token - The automatically generated key that is used for logging in to Salesforce from an untrusted network. See the Salesforce documentation to learn how to get or reset your security token.

 

OAuth 2.0 authentication

 

To connect with OAuth 2.0 authentication, perform the following steps:
 

1.In Authentication type, select AccessRefreshToken.
2.Click Sign In.
3.Log in to Salesforce with your username and password.

After this, the Refresh Token parameter will be filled in automatically, and you'll be able to connect.

OAuth 2.0 authentication has the following benefit: you enter your account email and password directly to Salesforce webpage, and they are not used or stored in Excel. You also don't need to get and specify Salesforce security token.

In addition to the parameters above, Advanced connection parameters may be set for more fine connection tuning. You can also fill Client Id, Client Secret, and Refresh Token parameters manually in the Advanced Connection Editor dialog box.

For more information on how to configure your own app for authentication and obtain the Client ID and Client Secret (Consumer Key and Consumer Secret), see Get Credentials for OAuth Authentication.

 

Server-to-server authentication
 

Server-to-server authentication uses the OAuth 2.0 client credentials flow and enables applications to access Salesforce data without interactive user sign-in. Instead of signing in through a browser, the application authenticates using a consumer key and consumer secret.

To connect with server-to-server authentication:

1.In Authentication, select ClientCredentials.
2.In Host, select the Salesforce login URL.
3.Enter your Client ID (Consumer Key) and Client Secret (Consumer Secret).
4.Optional: To specify how connection data is saved and reused in Excel, configure the connection saving options. For more information, see Connecting and Importing Data.
5.Optional: To configure advanced connection options, click Advanced.
6.Optional: To verify that the connection details are valid, click Test Connection.
7.Click Next.

salesforce-clientcredentials-authentication-type

For information about how to create an external client app and get the Client ID (Consumer Key) and Client Secret (Consumer Secret), see Get Credentials for Server-to-Server Authentication.

 

ExpandedToggleIcon        Advanced Connection Options

The following table describes the options that you can include in the Connection String using the Advanced Connection Editor dialog box:

 

Option

Description

Authentication Type

Determines the authentication method to use when connecting to Salesforce.

Batch Size

Specifies the number of records returned by a service at once. The default value is 500; the minimum is 200, and the maximum is 2,000.

Client ID

Specifies the Consumer Key from the connected app definition. Used for the OAuth Refresh Token authentication.

Client Secret

Specifies the Consumer Secret from the connected app definition. Used for the OAuth Refresh Token authentication.

Connection Lifetime

Specifies the time span (in seconds), compared against a connection's creation time when it is returned to the pool; the connection is destroyed if this span is exceeded. The default value is 0 (connection always returns to pool).

Connect Timeout -or- Connection Timeout

Specifies the length of time (in seconds) to wait for a connection to the server before terminating the attempt and generating an error. The default value is 60.

Default Command Timeout

Specifies the time in seconds to wait while trying to execute a command before terminating the attempt and generating an error.

Failover Retries

Specifies the number of retry attempts to automatically re-run a command before displaying an error message in case when the command failed because of an error that may be temporary.

Host

Specifies the Salesforce.com or Database.com login URL.

Ignore Blank Values

Determines whether to ignore blank field values instead of treating them as explicit nulls during insert or update operations.

Include Deleted

Determines, whether to include deleted records from recycle bin to results when querying data from Salesforce.

Initialization Command

Specifies a database-specific command to execute after establishing the connection.

Local SQL Engine

Determines whether to use local SQL engine for SELECT queries, that are too complex to translate them directly to Salesforce API calls or to show an error message.

Max Pool Size

Specifies the maximum number of connections allowed in the pool. Setting the Max Pool Size value in the connection string can affect performance. The default value is 100.

Min Pool Size

Specifies the minimum number of connections allowed in the pool. The default value is 0.

NormalizeDbNames

Determines whether database object names are normalized when retrieved from the database.

Organization Id

Specifies a unique identifier for the Salesforce organization to which the account you connect to belongs.

Password

Specifies the password for the account.

Persist Security Info

Indicates if security-sensitive information, such as the password, is not returned as part of the connection if the connection is open or has ever been in an open state.

Pooling

Draws the connection from the appropriate pool, or creates and adds it to the appropriate pool, when set to true. This is the default behavior.

Preserve Names

Determines whether to preserve the original Salesforce field and object names.

Proxy Host

Specifies the host name or IP address of the proxy server.

Proxy Password

Specifies the password for the proxy server account.

Proxy Port

Specifies the port number of the proxy server. The default value is 3128.

Proxy User

Specifies the proxy server account name.

Readonly

Indicates whether the connection is read-only (allows only SELECT statements).

Refresh Token

Specifies the Salesforce OAuth 2.0 refresh token. Used for the OAuth Refresh Token authentication.

Run Once Command

Specifies a database-specific command to execute after establishing the connection. Unlike Initialization Command, it is not executed for connections obtained from the connection pool.

Security Token

Specifies the automatically generated key that is used for logging in to Salesforce from an untrusted network.

Session Id

Specifies the Salesforce session ID for the session ID authentication.

Token Server

Specifies the path to a file to store the refresh token between sessions. It is used for UserNamePassword and AccessRefreshToken authentication. This parameter is specified automatically when performing web login, and in most cases there is no need to modify it. If you want, you may specify a custom path to use instead of the default one.

Trigger Auto Response Email

Specifies whether to trigger auto-response rules or not. Default value is false.

Trigger Other Email

Specifies whether to trigger email outside the organization or not. The default value is false.

Trigger User Email

Specifies whether to trigger email that is sent to users in the organization or not. The default value is false.

Update Mru

Specifies whether to update the list of most recently used items or not.

Use Assignment Rules

Determines whether to use assignment rules when inserting or updating data. The default value is false.

User Id

Specifies the Salesforce login account.

UTC Dates

Converts dates to UTC format during import when set to True; the date values entered in Excel are then considered UTC dates when saving them to the data source.