可以使用StartsWith查询PartitionKey吗? [英] Can PartitionKey be queried with StartsWith?

查看:103
本文介绍了可以使用StartsWith查询PartitionKey吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在Azure表存储中,是否可以使用StartsWith或其他一些运算符查询PartitionKey包含等

In Azure Table Storage, is it possible to query PartitionKey with a StartsWith or some other operator e.g. Contains, etc.

我知道我可以用RowKeys做到这一点,但是可以用PartitionKeys做到吗?

I know I can do this with RowKeys but is it possible to do it with PartitionKeys?

一个后续问题是:即使可行,它是否明智?分区键是否应该始终完全匹配-例如出于性能方面的考虑?

A follow up question is: even if it's doable, is it advisable? Should PartitionKey always be an exact match -- say, for performance reasons?

推荐答案

好消息是,您可以进行部分匹配,只要要击中的分区数量很少,您将获得良好"的性能.如果您有很多分区键,则会影响性能.

Well, the good news is that you CAN do partial matches, and you will get "good" performance as long as the number of partitions being hit is small. If you have lots of partition keys, performance will suffer.

我可以尝试总结一个出色的文章,但是已经写好了,因此,如果将浏览器指向以下链接,则应该了解所有有关分区,行键和预期性能的信息:

I could try to summarize an excellent write-up on this, but it's already written, so if you point your browser to the following link, you should learn all there is to know about partitions, rowkeys, and expected performaces:

https://msdn.microsoft.com/en-us/library/azure/hh508997.aspx

这篇关于可以使用StartsWith查询PartitionKey吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆