Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why does Google App Engine restrict GQL queries?

I was reading about App Engine on wikipedia and came across some GQL restrictions:

  • JOIN is not supported

  • can SELECT from at most one table at a time

  • can put at most 1 column in the WHERE clause

What are the advantages of these restrictions?

Are these restrictions common in other places where scalability is a priority?

like image 717
MrDatabase Avatar asked Nov 14 '08 06:11

MrDatabase


People also ask

What is Gql in Datastore?

A GQL query returns zero or more entire entities, projected entities, or keys of the requested kind. Every GQL query always begins with SELECT * , SELECT __key__ or SELECT <property list> , where property is a comma delimited list of one or more entity properties to be returned from the query.

What is the query language we can use with Datastore?

The Python Datastore API provides two classes for preparing and executing queries: Query uses method calls to prepare the query. GqlQuery uses a SQL-like query language called GQL to prepare the query from a query string.


1 Answers

The datastore that GQL talks to is:

  • not a relational database like MySQL or PostgreSQL
  • is a Column-oriented DBMS called BigTable

One reason to have a database like this is to have a very high performance database that you can scale across hundreds of servers.

GQL is not SQL it is SQL-like.

Here are some references:

  • http://en.wikipedia.org/wiki/Column-oriented_DBMS
  • http://en.wikipedia.org/wiki/BigTable
  • http://code.google.com/appengine/docs/datastore/overview.html
  • http://code.google.com/appengine/docs/datastore/gqlreference.html
like image 53
Dave Jensen Avatar answered Oct 02 '22 11:10

Dave Jensen