This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -85,7 +85,7 @@ Some examples of databases that work like this could be **PostgreSQL**, **MySQL*
### Distributed servers
In some cases, the database could even be a group server applications running on different machines, working together and communicating between them to be more efficient and handle more data.
In some cases, the database could even be a group of server applications running on different machines, working together and communicating between them to be more efficient and handle more data.
In this case, your code would talk to one or more of these server applications running on different machines.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -107,7 +107,7 @@ Most of that should look familiar:
The column will be named `team_id`. It will be an integer, and it could be `NULL` in the database (or `None` in Python), becase there could be some heroes that don't belong to any team.
As we don't have to explicitly pass `team_id=None` when creating a hero, we add a default of `None` to the `Field()`.
We add a default of `None` to the `Field()` so we don't have to explicitly pass `team_id=None` when creating a hero.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
That would end up in the same result. Although we won't use that for **SQLModel**.
### `SELECT` Less Columns
### `SELECT` Fewer Columns
We can also `SELECT` less columns, for example:
We can also `SELECT` fewer columns, for example:
```SQL
SELECT id, name
Expand Down
Expand Up
@@ -150,7 +150,7 @@ Another variation is that most of the SQL keywords like `SELECT` can also be wri
This is the interesting part. The tables returned by SQL databases **don't have to exist** in the database as independent tables. 🧙
For example, in our database, we only have one table that has all the columns, `id`, `name`, `secret_name`, `age`. And here we are getting a result table with less columns.
For example, in our database, we only have one table that has all the columns, `id`, `name`, `secret_name`, `age`. And here we are getting a result table with fewer columns.
One of the main points of SQL is to be able to keep the data structured in different tables, without repeating data, etc, and then query the database in many ways and get many different tables as a result.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -271,7 +271,7 @@ In the example above we are using two equal signs (`==`). That's called the "**e
!!! tip
An **operator** is just a symbol that is put beside one value or in the middle of two values to do something with them.
`==` is called **equality** operator because it checks if two things are **equal**.
`==` is called the **equality** operator because it checks if two things are **equal**.
When writing Python, if you write something using this equality operator (`==`) like:
Expand Down
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
✏ Fix multiple typos and some rewording #22
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Uh oh!
There was an error while loading. Please reload this page.
✏ Fix multiple typos and some rewording #22
Filter by extension
Viewed files
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
There are no files selected for viewing