在现有的实体属性上创建索引 [英] Creating indexes on existing entity properties

查看:171
本文介绍了在现有的实体属性上创建索引的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我开始使用我的项目时,我认为不需要在某些实体字段上创建索引,但要生成某些日常报告,我们需要在现有实体的某些字段上创建索引的统计信息。



正如后面的 GAE数据存储中的追溯索引,唯一的方法是首先将这些属性从未索引编制为索引,然后再次检索并写入所有实体。



我的问题是,如果我备份从数据存储管理员并将属性更改为索引后恢复,我的项目是否具有索引的所有必需属性?或者我需要通过一个程序检索和写入?



PS:我的项目是GAE上的一个Java项目

解决方案

编辑:解决我之前提到的问题无效。更改字段的唯一方法是重新上传实体。对不起。

When I started off with my project, I thought there was no need to create indexes on certain fields of entities but to generate certain daily reports, statistics we have a need to create indexes on some fields of existing entities.

As explained in the post Retroactive indexing in GAE Datastore, only way is to first change these properties from unindexed to indexed then retrieve and write all the entities again.

My question is if I take a back up from Datastore Admin and restore after changing the properties to indexed, will my project have all the required properties indexed? or do I need to retrieve and write through a program?

PS: My project is a java project on GAE

解决方案

Edit: Work around I mentioned earlier does not work. The only way to change the field is to re-upload the entities. Sorry.

这篇关于在现有的实体属性上创建索引的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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