Skip to content

Azure Functions Managed Identity: Keyword not supported: 'authentication' #32

@Szeraax

Description

@Szeraax

When using a AZ Function MI, you need to use a connection string like: Server=a.database.windows.net; Authentication=Active Directory Managed Identity; Database=a but I get the error from AZ: Keyword not supported: 'authentication'.

Supposedly the fix is to use Microsoft.Data.SqlClient instead of System.Data.SqlClient. https://gist.github.com/MartinHBA/86c6014175758a07b09fa7bb76ba8e27

Perhaps Invoke-SqlCmd2 should detect if it has the Authentcation in the connection string and use MS.Data.Sql instead? Dunno.

More info: https://devblogs.microsoft.com/dotnet/introducing-the-new-microsoftdatasqlclient/

Shame that for lightweight query access, I have to revert to users and password. Or use dbatools.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions