Open
Description
Describe the bug
When my query doesn't work for table view, it suggests that I use --debug
to get more info, but that doesn't actually help.
Command Name
vm list
Errors:
Table output unavailable. Use the --query option to specify an appropriate query. Use --debug for more info.
To Reproduce:
az>> configure --defaults group=<MY REDACTED GROUP NAME>
az>> vm list --show-details --query '[].{Name:name, OS:storageProfile.osDisk.osType, Admin:osProfile.adminUsername}' --output table
Table output unavailable. Use the --query option to specify an appropriate query. Use --debug for more info.
az>> vm list --query '[].{Name:name, OS:storageProfile.osDisk.osType, Admin:osProfile.adminUsername}' --output table
Table output unavailable. Use the --query option to specify an appropriate query. Use --debug for more info.
az>> vm list --query '[].{Name:name, OS:storageProfile.osDisk.osType, Admin:osProfile.adminUsername}' --output table --debug
Table output unavailable. Use the --query option to specify an appropriate query. Use --debug for more info.
az>> vm list --debug --query '[].{Name:name, OS:storageProfile.osDisk.osType, Admin:osProfile.adminUsername}' --output table
Table output unavailable. Use the --query option to specify an appropriate query. Use --debug for more info.
az>> vm list --debug --query '[].{Name:name, OS:storageProfile.osDisk.osType, Admin:osProfile.adminUsername}' --output table
az>> az feedback
Expected Behaviour
It would print a table with the info I want or it would tell me why it can't do that.
Environment Summary
macOS-10.15.4-x86_64-i386-64bit
Python 3.8.2
Installer: HOMEBREW
azure-cli 2.5.1
Extensions:
interactive 0.4.4
Additional Context
Some of these were direct examples from https://docs.microsoft.com/en-us/cli/azure/query-azure-cli?view=azure-cli-latest. The json output looks like it should be trivial to display as a table:
az>> vm list --debug --query '[].{Name:name, OS:storageProfile.osDisk.osType, Admin:osProfile.adminUsername}' --output json
[
{
"Admin": "redacted",
"Name": "redacted",
"OS": "redacted"
},
{
"Admin": "redacted",
"Name": "redacted",
"OS": "redacted"
},
{
"Admin": "redacted",
"Name": "redacted",
"OS": "redacted"
},
{
"Admin": "redacted",
"Name": "redacted",
"OS": "redacted"
},
{
"Admin": "redacted",
"Name": "redacted",
"OS": "redacted"
},
{
"Admin": "redacted",
"Name": "redacted",
"OS": "redacted"
},
{
"Admin": "redacted",
"Name": "redacted",
"OS": "redacted"
},
{
"Admin": "redacted",
"Name": "redacted",
"OS": "redacted"
}
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment