question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

SqlDatabase.Inner.Tags isn't populated when loading databases from a SqlServer

See original GitHub issue

SqlDatabase.Inner.Tags isn’t populated when loading databases from a SqlServer.

var sqlServers = await AzureManagementClient.SqlServers.ListAsync();
foreach (var sqlServer in sqlServers)
{
  ...
  var databases = await sqlServer.Databases.ListAsync();
  foreach (var database in databases)
  {
       var tags = database.Inner.Tags; // Tags == null
  }
}

Doublechecked with PowerShell that the resource does have tags on it via:

$resource = Get-AzureRmResource -Name $resourceName -ResourceGroupName $resourceGroupName
$resource.Tags

Issue Analytics

  • State:open
  • Created 5 years ago
  • Reactions:1
  • Comments:8 (6 by maintainers)

github_iconTop GitHub Comments

3reactions
ghostcommented, Jun 15, 2021

What’s the status of this ticket? It’s 2021 and tags still do not get included in a call to ListBySqlServerAsync. Telling us to call refresh on each database returned is not viable considering we are listing thousands of databases. Can this get fixed properly?

0reactions
weidongxu-microsoftcommented, Nov 4, 2021

Database (not server) is still 2014

- Microsoft.Sql/stable/2014-04-01/databases.json

This SDK is in maintenance mode. New SDK is starting preview on https://aka.ms/azsdk/dotnet/mgmt (at present it does not have SQL yet).

Read more comments on GitHub >

github_iconTop Results From Across the Web

Database Engine events and errors - SQL Server
Consult this MSSQL error code list to find explanations for error messages for SQL Server database engine events.
Read more >
Contained databases in SQL Server
It includes all settings related to databases along with its metadata, thus system will be having no dependency with SQL server login.
Read more >
Recommended SQL database design for tags or tagging
Three tables (one for storing all items, one for all tags, and one for the relation between the two), properly indexed, with foreign...
Read more >
SQL Server Cannot drop database <dbname> because it is ...
A good approach would be to run a script which kills all sessions and immediately after rename the database to another name and...
Read more >
Building a SQL Server data dictionary - Simple Talk
A data dictionary is a documentation tool that provides metadata, metrics, or details about a database and the data within it.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found