Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot use entity variable in az storage entity insert using Azure CLI 2.40.0 #23932

Closed
rubenmiddel opened this issue Sep 19, 2022 · 4 comments
Closed
Assignees
Labels
Auto-Assign Auto assign by bot Azure CLI Team The command of the issue is owned by Azure CLI team customer-reported Issues that are reported by GitHub users external to the Azure organization. CXP Attention This issue is handled by CXP team. question The issue doesn't require a change to the product in order to be resolved. Most issues start as that Storage az storage
Milestone

Comments

@rubenmiddel
Copy link

rubenmiddel commented Sep 19, 2022

Related command
az storage entity insert

Describe the bug
Using a Powershell variable for inserting a Storage Entity results in error using Azure CLI 2.40. Same command was working fine in Azure CLI 2.37.0. Running the same command without using a variables also works fine.

To Reproduce

  1. Open a PowerShell window and set variables $storageAccount, $tableName, $partitionKey, $rowKey and $content to valid values
  2. Run the commands below and notice the error

$entity = @()
$entity += "PartitionKey=$partitionKey"
$entity += "RowKey=$rowKey"
$entity += "Content=$content"
az storage entity insert -t $tableName --account-name $storageAccount --auth-mode login -e $entity

Actual behavior
incorrect usage: entity requires: RowKey PartitionKey

Expected behavior
An entity is inserted to the table storage.

Environment summary
CLI version 2.40.0

Additional context

@ghost ghost added customer-reported Issues that are reported by GitHub users external to the Azure organization. Storage az storage labels Sep 19, 2022
@ghost ghost added this to the Backlog milestone Sep 19, 2022
@ghost ghost assigned evelyn-ys Sep 19, 2022
@ghost ghost added the Auto-Assign Auto assign by bot label Sep 19, 2022
@rubenmiddel rubenmiddel changed the title Cannot use entity variable in az storage entity insert in Azure CLI 2.40.0 Cannot use entity variable in az storage entity insert using Azure CLI 2.40.0 Sep 19, 2022
@yonzhan
Copy link
Collaborator

yonzhan commented Sep 19, 2022

@evelyn-ys for awareness

@yonzhan yonzhan added Azure CLI Team The command of the issue is owned by Azure CLI team question The issue doesn't require a change to the product in order to be resolved. Most issues start as that labels Sep 19, 2022
@evelyn-ys
Copy link
Member

Similar with #23797. Please see detailed info in #23797 's comments

@yonzhan yonzhan added the CXP Attention This issue is handled by CXP team. label Sep 20, 2022
@ghost
Copy link

ghost commented Sep 20, 2022

Thank you for your feedback. This has been routed to the support team for assistance.

@rubenmiddel
Copy link
Author

rubenmiddel commented Sep 20, 2022

@evelyn-ys Thank you, using @entity to pass the variable in the insert command fixes the issue!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Auto-Assign Auto assign by bot Azure CLI Team The command of the issue is owned by Azure CLI team customer-reported Issues that are reported by GitHub users external to the Azure organization. CXP Attention This issue is handled by CXP team. question The issue doesn't require a change to the product in order to be resolved. Most issues start as that Storage az storage
Projects
None yet
Development

No branches or pull requests

3 participants