Hi,

I am unable to replicate the issue you are having on the dev_appserver.  For
instance, the following program executes as expected for me:
class Test(db.Model):
  mystr = db.StringProperty(default="Hell")
  date = db.DateTimeProperty(auto_now_add=True)

class MainPage(webapp.RequestHandler):
  def get(self):
    new_test = Test()
    new_test.put()
    date_count = Test.gql('ORDER BY date LIMIT 100').count()
    self.response.out.write(date_count)

With the count correctly updating every time the handler is called.

Can you provide more information on the SDK version/ OS you are using, as
well as your Python installation?  What about the complete code that you are
running?

If the same datetime is recorded in all of your puts, this might be some
underlying issue with your computer's clock or your Python installation, but
I don't really have any idea what that could be.

Have you tried this code in production, and if so, did it work?

-Marzia

On Thu, Nov 20, 2008 at 7:03 AM, ZCm <[EMAIL PROTECTED]> wrote:

>
> Hi !
> I have model
>
> class RawData(db.Model):
>        raw = db.StringProperty(multiline=True)
>        date = db.DateTimeProperty(auto_now_add=True)
>
> somvere in my code i try
>
> ...
> query = RawData.gql("ORDER BY date LIMIT 100")
> query_length = query.count()
> but it returns that query_length is 0 ! but without "ORDER BY date
> LIMIT 100" query works.
>
> The next problem is the same datetime in all records in my
> RawData.date (when i try it run on Development Server)
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To post to this group, send email to google-appengine@googlegroups.com
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to