Hi Ryan,Thanks for your reply. Allow me to clarify my question, since I
poorly worded it.
Let's say we are using the guestbook sample application. Here we use a
descending single property index for the following query:
greetings = db.GqlQuery("SELECT * "
"FROM Greeting "
"ORDER BY date DESC LIMIT 10")
Now as you said there are two tables, one ascending and one descending. For
this example we would do a scan on the descending table for the first 10,
where the top of the table would have the most recent Greeting entries. From
my understanding the keys would be:
Greeting/date/<timestamp>/<unique path key>
Is this correct? So an example set of indexes would look like:
Greeting/data/09:00:00/Greeting:3
Greeting/data/08:00:00/Greeting:2
Greeting/data/07:00:00/Greeting:1
If so, what I do not understand is how Big Table can sort these indexes on
descending order of the date as in the above example.
It looks to me that you'd have to pull in the entire table and grab the last
10 given you can't do reverse lexicographical ordering, or reverse scans. Am
I missing something obvious here or holding some false assumption?
Also, I meant to compare slides 33 to 32, not 22, which was a typo. Sorry.
Thanks,
Navraj
P.S. I love the fact that you guys go into so much depth on the backend of
GAE. It gives me confidence in that you guys have a solid and scalable
service.
On Thu, Sep 17, 2009 at 11:36 PM, ryan
<[email protected]<ryanb%[email protected]>
> wrote:
>
> also...
>
> On Sep 17, 3:45 am, "Navraj S. Chohan" <[email protected]> wrote:
>
> > On slide 33 of the under the covers talk (
> http://snarfed.org/space/datastore_talk.html) the Kind and Name of the
> > index are lexicographical while the value is reversed (compared to slide
> 22).
>
> i alluded to the fact that we have different tables for each direction
> on slide 29: "Single-property index...one ascending, one descending."
>
> still, i can understand the confusion. when i give talks with slides,
> i usually don't intend for the slides to be self contained or fully
> usable on their own. they're really just visual aids for what i say
> out loud. if you have the time, i'd encourage you to watch the talk
> videos! for example:
>
>
> http://sites.google.com/site/io/under-the-covers-of-the-google-app-engine-datastore
>
> http://code.google.com/events/io/sessions/TransactionsAcrossDatacenters.html
>
> >
>
--
Navraj S. Chohan
[email protected]
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google App Engine" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/google-appengine?hl=en
-~----------~----~----~----~------~----~------~--~---