Skip to content

Commit

Permalink
Merge pull request #2485 from dolthub/gitbook-dev
Browse files Browse the repository at this point in the history
add limit to embedded query
  • Loading branch information
liuliu-dev authored Jan 30, 2025
2 parents 5aeb21d + 7d2ca97 commit fb68153
Showing 1 changed file with 16 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -464,7 +464,7 @@ Consider the following example table `city`:
To find who set the current values, we can query the `dolt_blame_city` table:
{% embed url="https://www.dolthub.com/repositories/dolthub/first-hour-db/embed/main?q=select+*+from+dolt_blame_city%3B" %}
{% embed url="https://www.dolthub.com/repositories/dolthub/first-hour-db/embed/main?q=select+*+from+dolt_blame_city+limit+20%3B" %}
## `dolt_commit_ancestors`
Expand Down Expand Up @@ -1242,48 +1242,48 @@ For a hypothetical table `a` with the following schema:
```
Each row in the table represents a row in the primary table that is in violation of one or more
constraint violations. The `violation_info` field is a JSON payload describing the violation. The
constraint violations. The `violation_info` field is a JSON payload describing the violation. The
payload varies depending on the type of constraint violation recorded.
For **foreign key violations**:
```json
{
"ForeignKey": "key_name",
"Table": "myTable",
"Columns": ["col1", "col2"],
"Index": "myIdx",
"OnDelete": "RESTRICT",
"OnUpdate": "RESTRICT",
"ReferencedColumns": ["col3", "col4"],
"ReferencedIndex": "myIdx2",
"ReferencedTable": "refTable"
"ForeignKey": "key_name",
"Table": "myTable",
"Columns": ["col1", "col2"],
"Index": "myIdx",
"OnDelete": "RESTRICT",
"OnUpdate": "RESTRICT",
"ReferencedColumns": ["col3", "col4"],
"ReferencedIndex": "myIdx2",
"ReferencedTable": "refTable"
}
```
For **unique constraints**:
```json
{
"Name": "constraint_name",
"Columns": ["col1", "col2"]
"Name": "constraint_name",
"Columns": ["col1", "col2"]
}
```
For **not null constraints**:
```json
{
"Columns": ["col1", "col2"]
"Columns": ["col1", "col2"]
}
```
For **check constraints**:
```json
{
"Name": "constraint_name",
"Expression": "(col1 > 0)"
"Name": "constraint_name",
"Expression": "(col1 > 0)"
}
```
Expand Down

0 comments on commit fb68153

Please sign in to comment.