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.

Looking for example and more information on BlobServiceClient.findBlobsByTags() and BlockBlobClient.query() APIs

See original GitHub issue

Query/Question How can we help?

Environment:

  • Name and version of the Library package used: [e.g. Azure.Storage.Blobs 12.2.0] @azure/storage-blob@12.4.0
  • Hosting platform or OS and .NET runtime version (dotnet --info output for .NET Core projects): [e.g. Azure AppService or Windows 10 .NET Framework 4.8]
  • IDE and version : [e.g. Visual Studio 16.3]
  1. We are looking for complete example for BlobServiceClient.findBlobsByTags() usage in the implementation. We have tried searching but could not find any example format for the tagFilterSqlExpression parameter. Also, looking for exact use case reference for using the tags for the blobs.

  2. We are looking for complete example for BlockBlobClient.query() usage in the implementation. We have tried searching but could not find any example for searching the blob content data. Also, looking for exact use case reference for using the query for searching the blob content.

  • Also, please share the reference for the query language used.
  • For Example:
    • Blob Name: Expenses_Month _Wise_Year_2020.csv - this file contains all the expenses occurred in every month where Month is column.
      • Blob Name: Income_Month _Wise_Year_2020.csv - this file contains all the incomes from every month where Month is column.
    • Use Case 1: Retrieve the blobs which has the value as January where the column name is Month using query. (retrieving the blobs from the Container based on blobs data)
    • Use Case 2: Retrieve the blob data which has the value as January where the column name is Month.(retrieving data from single blob)

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:20 (11 by maintainers)

github_iconTop GitHub Comments

1reaction
prashanthmadduricommented, Feb 1, 2021

Like I said, could you please refer to the linked test cases for example for now? We probably won’t add samples for these two features until they are GA.

https://github.com/Azure/azure-sdk-for-js/blob/388c649b281981dbef5b1bb519195c4ffdc74d17/sdk/storage/storage-blob/test/blobserviceclient.spec.ts#L474-L550

The sequences are

  • create blob with tags (key value pairs) or call setTags() after creation
  • call BlobServiceClient.findBlobsByTags(), the result type is just like that of listBlobs. It can be scoped to a particular container with @container = 'videofiles'.

Thank you @ljian3377, The example for BlobServiceClient.findBlobsByTags() working as expected.

Now only we only need steps for Enable query acceleration from UI. If you could provide some inputs that will help us.

0reactions
msftbot[bot]commented, Jan 21, 2022

Hi @prashanthmadduri, since you haven’t asked that we “/unresolve” the issue, we’ll close this out. If you believe further discussion is needed, please add a comment “/unresolve” to reopen the issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

BlobServiceClient.FindBlobsByTags(String ...
The Filter Blobs operation enables callers to list blobs across all containers whose tags match a given search expression. Filter blobs searches across...
Read more >
Class BlobServiceClient | Azure SDK for .NET
Initializes a new instance of the BlobServiceClient class for mocking. ... For more information, Configure Azure Storage connection strings.
Read more >
Azure blob storage - findBlobsByTags always fails with error ...
I updated the query as below and it works fine. BlobServiceClient blobServiceClient = getBlobServiceClient(); PagedIterable<TaggedBlobItem> ...
Read more >
Azure Storage Blob client library for JavaScript - npm
Please see the README for @azure/identity for more details and samples to ... getContainerClient() to get a container client instance then ...
Read more >
BlobServiceClient (Azure SDK for Java Reference ...
For more information, see the Azure Docs. Code Samples client.listBlobContainers().forEach(container -> System.out.printf("Name: %s%n", container.
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