mirror of
https://github.com/supabase/supabase.git
synced 2026-10-05 17:35:10 +03:00
dart update codeblocks showing
This commit is contained in:
1 parent
52e04c18d3
commit
ccec09fe72
1 file changed
+7
-5
@@ -539,15 +539,16 @@ functions:
|
||||
```
|
||||
|
||||
- id: update
|
||||
title: 'Modify data: update()'
|
||||
description: |
|
||||
Performs an UPDATE on the table.
|
||||
title: 'Modify data: update()'
|
||||
notes: |
|
||||
- `update()` should always be combined with [Filters](/docs/reference/dart/using-filters) to target the item(s) you wish to update.
|
||||
examples:
|
||||
- name: Updating your data
|
||||
- id: updating-your-data
|
||||
name: Updating your data
|
||||
isSpotlight: true
|
||||
dart: |
|
||||
code: |
|
||||
```dart
|
||||
final res = await supabase
|
||||
.from('cities')
|
||||
@@ -555,13 +556,14 @@ functions:
|
||||
.match({ 'name': 'Auckland' })
|
||||
.execute();
|
||||
```
|
||||
- name: Updating JSON data
|
||||
- id: updating-json-data
|
||||
name: Updating JSON data
|
||||
description: |
|
||||
Postgres offers a
|
||||
[number of operators](https://www.postgresql.org/docs/current/functions-json.html)
|
||||
for working with JSON data. Right now it is only possible to update an entire JSON document,
|
||||
but we are [working on ideas](https://github.com/PostgREST/postgrest/issues/465) for updating individual keys.
|
||||
dart: |
|
||||
code: |
|
||||
```dart
|
||||
final res = await supabase
|
||||
.from('users')
|
||||
|
||||
Reference in new issue
Block a user