I'm trying to use a cursor in my GQL query. According to Google Cloud Datastore grammar and a following example, I could do something like this:
people = Person.all().filter("age >", 18)
start_cursor = memcache.get('person_start_cursor')
if start_cursor:
people.with_cursor(start_cursor)
query_people = db.GqlQuery("SELECT * FROM Person WHERE age < 65 LIMIT @start_cursor 2")
for person in query_people:
self.response.out.write('<p><b>Name:</b> %s ' % person.name)
I obtain the error: "BadQueryError: Parse Error: Non-number limit in LIMIT clause at symbol @start_cursor". What I'm doing wrong? The cursor is not well defined? I've followed this steps
Thanks in advance!