This is possible. If you set the OAuthSettingsLocation property using the Other property, you can perform parallel processing of data. You can set the property in the DSN or dynamically in a DSN-less connection (see the code sample below).
OAuthSettingsLocation - The location of the settings file where OAuth values are saved. This can be any location on disk for which the driver has read/write permissions.
Performing OAuth Using the DSN Manager
You will need to authenticate with the service before using the driver. To do so, you can use the Test Connection in the DSN Wizard.
- Open the ODBC Data Source Administrator (from the Start Menu, type "ODBC")
- Select or create a new DSN using the driver.
- Set the OAuthSettingsLocation property in the Other property and click Test Connection. (You will be prompted to authenticate with the service in a new browser window.)
Code Sample
string driver = "CData ODBC Driver for QuickBooksOnline";
string oauthSettingsLocation = "C:/users//AppData/Roaming/CData/QuickBooksOnline ODBC Driver";
string connString = "DRIVER={" + driver + "};Other=OAuthSettingsLocation=" + oauthSettingsLocation;
Task task1 = Task.Factory.StartNew(() => ReadData(new OdbcConnection(connString)));
Task task2 = Task.Factory.StartNew(() => ReadData(new OdbcConnection(connString)));
Task task3 = Task.Factory.StartNew(() => ReadData(new OdbcConnection(connString)));
Task task4 = Task.Factory.StartNew(() => ReadData(new OdbcConnection(connString)));
Task task5 = Task.Factory.StartNew(() => ReadData(new OdbcConnection(connString)));
NOTE
CData Software also makes ADO.NET Providers that might provide a more native experience in .NET applications.