Connection strings for SharePoint

ACE OLEDB 12.0

Type OLE DB Provider
Usage Provider=Microsoft.ACE.OLEDB.12.0
Manufacturer Microsoft

Read, update and delete

Provider=Microsoft.ACE.OLEDB.12.0;WSS;IMEX=2;RetrieveIds=Yes;
DATABASE=http://mysharepointsite.com/documents/;LIST={5999B8A0-0C2F-4D4D-9C5A-D7B146E49698};

The keyword "Database" specifies the SharePoint URL

The keyword "List" specifies the GUID value for the desired SharePoint list (list=table)

Query without specifying table names. Ie use "SELECT FROM table" or "SELECT FROM list" (same result from booth).

Read more about Finding the Id (Guid) for a SharePoint List.

 
 

Read only

Provider=Microsoft.ACE.OLEDB.12.0;WSS;IMEX=1;RetrieveIds=Yes;
DATABASE=http://mysharepointsite.com/documents/;LIST={5999B8A0-0C2F-4D4D-9C5A-D7B146E49698};
 
 

Write

Provider=Microsoft.ACE.OLEDB.12.0;WSS;IMEX=0;RetrieveIds=Yes;
DATABASE=http://mysharepointsite.com/documents/;LIST={5999B8A0-0C2F-4D4D-9C5A-D7B146E49698};

Use different SharePoint list connections for read (IMEX=2) and writes (IMEX=0), do not mix them.

 
 

.NET Framework Data Provider for OLE DB

Type .NET Framework Wrapper Class Library
Usage System.Data.OleDb.OleDbConnection
Manufacturer Microsoft

Use an OLE DB provider from .NET

Provider=any oledb provider's name;OledbKey1=someValue;OledbKey2=someValue;

See the respective OLEDB provider's connection strings options. The .net OleDbConnection will just pass on the connection string to the specified OLEDB provider. Read more here.

 
 

Camelot .NET Connector for Microsoft SharePoint

Type .NET Framework Class Library
Usage Camelot.SharePointConnector.Data.SharePointConnection
Manufacturer Bendsoft

Standard

Server=myServerAddress;Database=mySite;Domain=myDomain;User=myUsername;
Password=myPassword;

NTLM is default authentication method. Domain and Database are optional parameters.

 
 

Using SSL encryption

Server=myServerAddress;Database=mySite;Domain=myDomain;User=myUsername;
Password=myPassword;SSL=True;

Always use SSL, deny connection if server does not support SSL or certificate is invalid.

 
 

Specifying Office365 authentication

Server=myServerAddress;Database=mySite;User=myUsername;Password=myPassword;
Authentication=365;

Connect to Office365 (SharePoint Online) using token based authentication.

 
 

Specifying Default authentication

Server=myServerAddress;Database=mySite;Authentication=Default;

Connect to server using default authentication, meaning the authenticated user under which the application is running or is impersonated.

 
 

Popular