Re: [google-appengine] Since Monday, these simple SQL operations translate to expensive DataStore operations, why?

2011-11-14 Thread karthik valsatech
On Tue, Nov 8, 2011 at 4:37 PM, Alberto Valaz alberto.va...@gmail.comwrote:

 I noticed that a number of simple SQL operations that my application
 is dependent on generate very high quota usage.
 Basically, one run of the three operations listed below are enough to
 use up my daily free quota!!


 I assume I am doing something very wrong but I am not sure how to fix
 it. Could anyone please give me

  thank you


 PS. an interesting twist is that the below code worked just fine under
 the old payment model.


 -
 // The table Something below has around 50k rows. No indexes are used.

 PersistenceManager pm = ...


 // Select COUNT(*) from Something
 Query q = pm.newQuery(Something.Class, null);
 q.setResult(count(this));
 q.execute();



 // select COUNT(*) from Something where 1234  feild
 Query q = pm.newQuery(Something.Class, this.field  field);
 q.declareParameters(Long field);
 q.setResult(count(this));
 q.executeWithArray(1234);


 // select * from Something order total DESC
 Query q = pm.newQuery(Something.Class, null);
 q.setOrdering(total DESC);
 q.execute();

 --
 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
 google-appengine+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/google-appengine?hl=en.



-- 
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 
google-appengine+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en.



[google-appengine] Since Monday, these simple SQL operations translate to expensive DataStore operations, why?

2011-11-13 Thread Alberto Valaz

I noticed that a number of simple SQL operations that my application
is dependent on generate very high quota usage.
Basically, one run of the three operations listed below are enough to
use up my daily free quota!!

Running appstats, I see a lot of datastore_v3.Next calls for the
first two calls. I assume I am doing something very wrong but I am not
sure how to fix it.  Could anyone please give me some pointers on how
to address this?

thank you


PS. an interesting twist is that the below code worked just fine under
the old payment model.


-
// The table Something below has around 50k rows. No indexes are used.

PersistenceManager pm = ...


// Select COUNT(*) from Something
Query q = pm.newQuery(Something.Class, null);
q.setResult(count(this));
q.execute();



// select COUNT(*) from Something where 1234  feild
Query q = pm.newQuery(Something.Class, this.field  field);
q.declareParameters(Long field);
q.setResult(count(this));
q.executeWithArray(1234);


// select * from Something order total DESC
Query q = pm.newQuery(Something.Class, null);
q.setOrdering(total DESC);
q.execute();

-- 
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 
google-appengine+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en.



[google-appengine] Since Monday, these simple SQL operations translate to expensive DataStore operations, why?

2011-11-13 Thread Alberto Valaz
I noticed that a number of simple SQL operations that my application
is dependent on generate very high quota usage.
Basically, one run of the three operations listed below are enough to
use up my daily free quota!!


I assume I am doing something very wrong but I am not sure how to fix
it. Could anyone please give me

thank you


PS. an interesting twist is that the below code worked just fine under
the old payment model.


-
// The table Something below has around 50k rows. No indexes are used.

PersistenceManager pm = ...


// Select COUNT(*) from Something
Query q = pm.newQuery(Something.Class, null);
q.setResult(count(this));
q.execute();



// select COUNT(*) from Something where 1234  feild
Query q = pm.newQuery(Something.Class, this.field  field);
q.declareParameters(Long field);
q.setResult(count(this));
q.executeWithArray(1234);


// select * from Something order total DESC
Query q = pm.newQuery(Something.Class, null);
q.setOrdering(total DESC);
q.execute();

-- 
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 
google-appengine+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en.