Target Version: NServiceBus 5.x
Standard support for version 5.x of NServiceBus has expired. For more information see our Support Policy.


The SQL Server Transport address has the following canonical form:


The table name is a bracket-delimited identifier without surrounding square brackets. The following characters are allowed:

  • Whitespaces
  • Brackets but they must be escaped, e.g. my table and my]]table

The surrounding brackets are added automatically by SQL Server transport when executing the SQL statements.

The following characters are not valid:

  • @. All characters after @ (including @) are omitted when parsing addresses, e.g. my t@ble is parsed as my t.


The address is resolved into a qualified table name that includes both the table name and its schema. The schema has to be configured.


A schema for a destination endpoint can be specified either as a collection or via a callback:

var transport = busConfiguration.UseTransport<SqlServerTransport>();
var transport = busConfiguration.UseTransport<SqlServerTransport>();
transport.UseSpecificConnectionInformation(queueName =>
    if (queueName == "sales")
        return ConnectionInfo.Create()
    if (queueName == "billing")
        return ConnectionInfo.Create()
    if (queueName == "error")
        return ConnectionInfo.Create()
    return null;
Although the API uses the term Endpoint, the values provided/returned are physical queue names, not logical endpoint names as defined in Version 6 of NServiceBus.

The connection string convention is supported for backward compatibility. In the example below, the connection string NServiceBus/Transport/Billing overrides the default if sending to the Billing queue, in which case billingSchema is used.

  <add name="NServiceBus/Transport"
       connectionString="Data Source=instance; Initial Catalog=db; Integrated Security=True;Queue Schema=salesSchema"/>
  <add name="NServiceBus/Transport/Billing"
       connectionString="Data Source=instance; Initial Catalog=db; Integrated Security=True;Queue Schema=billingSchema"/>
    <add Messages="Sales.Contract"
    <add Messages="Billing.Contract"

Last modified