Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7520181
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T02:01:23+00:00 2026-05-30T02:01:23+00:00

Using AppEngine datastore, but this might be agnostic, no idea. Assume a database entity

  • 0

Using AppEngine datastore, but this might be agnostic, no idea.

Assume a database entity called Comment. Each Comment belongs to a User. Every Comment has a date property, pretty standard so far.

I want something that will let me: specify a User and get back a dictionary-ish (coming from a Python background, pardon. Hash table, map, however it should be called in this context) data structure where:

  • keys: every date appearing in the User‘s comment
  • values: Comments that were made on date.

I guess I could just iterate over a range of dates an build a map like this myself, but I seriously doubt I need to “invent” my own solution here.

Is there a way/tool/technique to do this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T02:01:24+00:00Added an answer on May 30, 2026 at 2:01 am

    Datastore supports both references and list properties. This let’s you build one-to-many relationships in two ways:

    1. Parent (User) has a list property containing keys of Child entities (Comment).

    2. Child has a key property pointing to Parent.

    Since you need to limit Comments by date, you’d best go with option two. Then you could query Comments which have date=somedate (or date range) and where user=someuserkey.

    There is no native grouping functionality in Datastore, so to also “group” by date, you can add a sort on date to the query. Than when you iterate over the result, when the date changes you can use/store it as a grouping key.

    Update

    Designing no-sql databases should be access-oriented (versus datamodel oriented in sql): for often-used operations you should be getting data out as cheaply (= as few operations) as possible.

    So, as a rule of thumb you should, in one operation, only get data that is needed at that moment (= shown on that page to user). I’m not sure about your app’s design, but I doubt you need all user’s full comments (with text and everything) at one time.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a Model called Version that looks like this: from google.appengine.ext import db
This is really a python language question, but its wrapped around a Google appengine
I'm using the Google AppEngine, with Java. When I use some datastore features, I'm
The Google App Engine Datastore allows each entity to have a parent entity ,
I'm trying my hand at google appengine and using the datastore with php and
I 'm trying to retrieve data from a datastore by using this (in example)
Since there is no way to join tables using Google App Engine datastore, I
while using the appengine sdk i can't view the Output of my System.out.println statements
I'm using the appengine webapp framework ( link ). Is it possible to add
I'm using Google appengine for developing an web application that is meant to be

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.