Skip to content

Any updated script that can be used for azure sql db connection? #92

@Coco-Kong

Description

@Coco-Kong

https://learn.microsoft.com/en-us/azure/devops/server/install/install-azure-sql?view=azure-devops-2022
It's possible to use ADO server with azure SQL db. but elastic search scipt provided here only works for onprem environment.

e.g.
$SqlFullPath = Join-Path $PWD -ChildPath 'CollectionDBDiagnosticScripts\IndexingUnitData.sql'
$queryResults = Invoke-Sqlcmd -InputFile $SqlFullPath -serverInstance $SQLServerInstance -database $CollectionDatabaseName

Invoke-Sqlcmd here uses windows logon, not azure managed identity. And there are many places in the script using Invoke-Sqlcmd. Hence it cannot connect to azure sql db.

Could you modify the script and share an updated version which can be used for azure sql db connection as well?

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