Search code examples
sql-serverssmsavailability-group

Invalid value for key 'applicationintent'. (System.Data)


I have installed SQL Server 2017 on Windows Server 2012 R2.

The servers are clustered under WSFC and SQL Servers are in availability group with configured availability group listener. Availability group is working fine.

I've installed SSDT on all servers but no luck.

When I set ApplicationIntent=Read-only in additional connection parameters, I get this error :

Invalid value for key 'applicationintent'. (System.Data)


Solution

  • ACcording to the official MS documentation, the possible values for ApplicationIntent are

    • ReadWrite
    • ReadOnly

    None of those values have a dash in them! So use this :

    ApplicationIntent=ReadOnly 
    

    in your connection string