【发布时间】:2013-06-30 01:56:37
【问题描述】:
我对 zigzag 合并连接算法有疑问。在文章https://developers.google.com/appengine/articles/indexselection中,提到了
Index(Photo, owner_id, -date),
Index(Photo, size, -date)
可以组合成
Index(Photo, owner_id, size, -date) ;
下面是我的测试:
<datastore-index kind="KindTest1" ancestor="false" source="auto">
<property name="hideIt" direction="asc"/>
<property name="voteCount" direction="desc"/>
</datastore-index>
<datastore-index kind="KindTest1" ancestor="false" source="auto">
<property name="hideIt" direction="asc"/>
<property name="createdByDate" direction="asc"/>
</datastore-index>
can these 2 indexes combine to become,
<datastore-index kind="KindTest1" ancestor="false" source="auto">
<property name="hideIt" direction="asc"/>
<property name="createdByDate" direction="asc"/>
<property name="voteCount" direction="desc"/>
</datastore-index>
我给你发邮件的原因是当我在开发和生产环境中尝试这个时,它不起作用并且需要每个单独的索引。可以详细说明吗?
【问题讨论】:
标签: google-app-engine google-cloud-datastore