Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I have a model which looks like this:

class Example (db.Model) :
 row_num = db.IntegerProperty(required=True)
 updated = db.IntegerProperty()
 ...
 ...

Now when i store values, I may not fill the value for the updated property every time, which implies that in some entities it may not exist.

I want to construct a datastore query so that i can get all entities of kind Example which do not have the property updated set.

How do i do this?

p.s. i know i can set a default value and then query on it. But the issue is i have over 3 million entities and updated will be marked only for 1% of them, so i do not want to waste so much of datastore space by setting the rest to 0.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
932 views
Welcome To Ask or Share your Answers For Others

1 Answer

Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...