Hi Vinny P!

my files looks something like this.

*main.py*
* class Action1(webapp2.RequestHandler):*
* def post(self):*
* blablabla*
*
*
* class Action2(webapp2.RequestHandler):*
* def post(self):*
* blablabla*
* *
* application = webapp2.WSGIApplication([*
* ('/act1', Action1),*
* ('/act2', Action2),*
* ], debug = True)*
and

*db.py*
* class User(db.Model):*
* user_name = db.StringProperty()*
* *
* class Mail(db.Model):*


act1 and act2 are 2 different ajax request.

I click on button 1 to POST to act1.
Good result is returned. I then check the database and the datas' are all 
there.

then I click on button 2 to POST to act2.
that's where the "fetch" runs.

I did some more tests just now but still no luck.

* query = db.GqlQuery( 'SELECT * FROM userMail WHERE user = :1', user_ref )*
* Log.add( "tmp1. try to fetch" )*
* rslt = query.fetch(1)*
* Log.add( "tmp1. got the rslt " + str(len(rslt)) )*
*
*
* query = db.GqlQuery( 'SELECT * FROM userMail WHERE mail = :1', mail_ref )*
* Log.add( "tmp2. try to fetch" )*
* rslt = query.fetch(1)*
* Log.add( "tmp2. got the rslt " + str(len(rslt)) )*
*
*
* query = db.GqlQuery( 'SELECT * FROM userMail WHERE user != :1', user_ref )
*
* Log.add( "tmp3. try to fetch" )*
* rslt = query.fetch(1)*
* Log.add( "tmp3. got the rslt " + str(len(rslt)) )*
*
*
* query = db.GqlQuery( 'SELECT * FROM userMail WHERE mail != :1', mail_ref )
*
* Log.add( "tmp4. try to fetch" )*
* rslt = query.fetch(1)*
* Log.add( "tmp4. got the rslt " + str(len(rslt)) )*
*
*
* query = db.GqlQuery( 'SELECT * FROM userMail WHERE user = :1', 
user_ref.key() )*
* Log.add( "tmp5. try to fetch" )*
* rslt = query.fetch(1)*
* Log.add( "tmp5. got the rslt " + str(len(rslt)) )*
*
*
* query = db.GqlQuery( 'SELECT * FROM userMail WHERE mail = :1', 
mail_ref.key() )*
* Log.add( "tmp6. try to fetch" )*
* rslt = query.fetch(1)*
* Log.add( "tmp6. got the rslt " + str(len(rslt)) )*
*
*
* query = db.GqlQuery( 'SELECT * FROM userMail WHERE user != :1', 
user_ref.key() )*
* Log.add( "tmp7. try to fetch" )*
* rslt = query.fetch(1)*
* Log.add( "tmp7. got the rslt " + str(len(rslt)) )*
*
*
* query = db.GqlQuery( 'SELECT * FROM userMail WHERE mail != :1', 
mail_ref.key() )*
* Log.add( "tmp8. try to fetch" )*
* rslt = query.fetch(1)*
* Log.add( "tmp8. got the rslt " + str(len(rslt)) )*

above codes are all good but

* query = db.GqlQuery( 'SELECT * FROM userMail WHERE user != :1 AND mail = 
:2', user_ref, mail_ref )*
or
* query = db.GqlQuery( 'SELECT * FROM userMail WHERE user != :1 AND mail = 
:2', user_ref.key(), mail_ref.key() )*

these 2 failed. (only fails on the real server lo)


Best, Hiro

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-appengine.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to