[Django]-How to create a new model (kind) in google cloud Datastore

5👍

Unlike SQL databases like MySQL, Cloud Datastore doesn’t require you to create kinds (similar to tables) in advance. Other than defining it in your code, no admin steps are required to create the kind.

When you write the first entity of that kind, it’s created implicitly for you.

You can even query for kinds that don’t exist yet without an error, you’ll just get no entities back:

Example GQL statement on a kind that doesn't exist, shows message of "No entities matched this query"

0👍

Of course you have to migrate, except if you are using the same database from the another project. Anyway if you type migrate it will create the tables from your models but if you are working with a existing database nothing is going to happen

Leave a comment