0
將鍵添加到數據存儲索引有一些限制嗎?Google App Engine Java - 索引和鍵碼
我Test.java
@EntityBean(entityGroup="TestRoot", entityGroupKeyName="TestList")
public class Test implements Serializable, JSONConvertible {
@Property(key=true,indexable=true)
private String keyName;
@Property(indexable=true)
private String userCode;
@Property(indexable=true)
private String name;
...
而在數據存儲區,indexes.xml:
<datastore-index kind="Flight" ancestor="true">
<property name="keyName" direction="desc"/>
</datastore-index>
<datastore-index kind="Flight" ancestor="true" source="manual">
<property name="keyName" direction="asc"/>
</datastore-index>
<datastore-index kind="Flight" ancestor="true">
<property name="userCode" direction="desc"/>
</datastore-index>
<datastore-index kind="Flight" ancestor="true" source="manual">
<property name="userCode" direction="asc"/>
</datastore-index>
<datastore-index kind="Flight" ancestor="true">
<property name="name" direction="desc"/>
</datastore-index>
<datastore-index kind="Flight" ancestor="true" source="manual">
<property name="name" direction="asc"/>
</datastore-index>
我有我的所有索引服務中的地位
當我爲了我的測試列表用「userCode」和「name」正常工作,但用「keyName」沒有幫助?
你如何使用@EntityBean與數據存儲? –