Taimoor Zaeem and Steve Chavez
e04cd70d83
refactor: move ApiRequestError to Error module
2025-02-13 09:38:18 -05:00
Steve Chavez and GitHub
307692c325
break: remove limited updated/delete feature ( #3907 )
...
BREAKING CHANGE
As agreed on https://github.com/PostgREST/postgrest/issues/3013#issuecomment-1770186262 ,
this removes the limited update/delete feature.
The feature was complicated, largely unused and caused other bugs in
mutations.
It was added in #2195 and #2211 .
2025-02-12 14:48:08 -05:00
Laurence Isla
b7d0a1f68c
feat: apply to_tsvector() explicitly to the full-text search filtered column, only if it's not of tsvector type
2025-01-28 19:14:54 -05:00
M. Taimoor Zaeem and Steve Chavez
a9d74eba2a
feat: allow not_null value for the is operator
2024-12-19 10:19:41 -05:00
Joel Jakobsson and GitHub
180a96ce48
remove support for Prefer: params=single-object ( #3757 )
...
BREAKING CHANGE
Using this preference was deprecated in 6c3d7a9 , in favor of Functions with an array of JSON objects.
2024-11-04 20:19:08 -05:00
jinjiadu and Wolfgang Walther
765696dfd0
chore: fix some typos in comments
2024-10-28 11:32:10 +01:00
Laurence Isla and GitHub
69bbce5b32
feat: improve PGRST121 error message
...
* Clarify the message field
* Show failed MESSAGE or DETAIL in the the PGRST121 error's details field
* Show the correct JSON format in the hint field
2024-04-24 13:33:10 -05:00
steve-chavez
a5bb20bbf8
refactor: remove unreacheable 404
2024-03-25 18:17:01 +01:00
Wolfgang Walther and Wolfgang Walther
8a21a9c34e
fix: Dump media handlers and timezones with --dump-schema
...
Those were left out of the schema dump when the features were introduced, probably
because ByteString doesn't have a toJSON instance. Changing the type to Text solves
this easily.
Resolves #3237
2024-02-20 18:44:17 +01:00
steve-chavez
6c3d7a946d
deprecate: params=single-object preference
2024-01-04 17:00:38 -05:00
Taimoor Zaeem and GitHub
0b77098460
feat: add max-affected preference to prefer header ( #3083 )
2023-12-18 18:35:23 -05:00
Laurence Isla and GitHub
d49e3d7132
fix: allow using special characters in json keys ( #3081 )
...
* increase memory size test
2023-12-06 17:28:51 -05:00
steve-chavez
3d56f8435d
chore: delete dead error codes
2023-11-28 10:25:25 -05:00
Tim Abdulla and GitHub
1c60b50e2e
Add aggregate functions ( #2925 )
...
The aggregate functions SUM(), MAX(), MIN(), AVG(), and COUNT() are now supported.
2023-11-23 14:03:03 -05:00
Taimoor Zaeem and GitHub
3c1a7f2641
feat: add timezone in Prefer header ( #3024 )
...
* increase reloading timeout in io-tests
* increase memory test by 1M
2023-11-13 14:16:27 -05:00
Taimoor Zaeem and GitHub
5c9c7f4ff4
fix: HTTP status responses for upserts
...
* PUT returns 201 instead of 200 when rows are inserted
* POST with "Prefer: resolution=merge-duplicates" returns 200 instead of 201 when no rows are inserted
2023-10-26 20:49:20 -05:00
steve-chavez
2aa58164ab
refactor: move errors to ApiRequestError
2023-10-06 01:16:45 -03:00
Taimoor Zaeem and Steve Chavez
3c1cdd434a
feat: add handling=strict/lenient for Prefer header
2023-09-27 15:00:52 -03:00
steve-chavez
d8a91453d1
fix: inconsistent Preference-Applied
...
* Don't apply `tx=commit` if the transaction doesn't commit
* Apply `count=exact`
* Also simplifies the Preference-Applied logic, removing the need for
some functions.
2023-09-12 13:52:49 -03:00
Taimoor Zaeem and Steve Chavez
d490bf09fd
feat: add Preference-Applied header in response for Prefer: return=representation/minimal/headers-only
2023-08-05 02:21:50 -05:00
steve-chavez
add10bd10c
test: doctest for addNullEmbedFilters
2023-07-06 16:52:46 -05:00
steve-chavez
52d3026133
refactor: remove unneeded FilterNullEmbed
2023-07-06 16:52:46 -05:00
steve-chavez
20b06efabe
chore: show on ReadPlan and MediaType
2023-07-05 17:35:54 -05:00
steve-chavez
feadf59bb3
refactor: rename Proc module to Routine
...
Assuming that functions=procedures is wrong since pg11, which introduced
real stored procedures.
2023-04-13 18:17:43 -05:00
steve-chavez
1b625cb77a
feat: any/all modifiers for operators
...
Only for the eq,like,ilike,gt,gte,lt,lte,match,imatch operators
2023-04-07 13:10:57 -05:00
Laurence Isla and GitHub
d3b10e7b2a
feat: Allow filtering by IS DISTINCT FROM using the isdistinct operator
2023-04-06 13:02:03 -05:00
steve-chavez
bc1fb67df0
drop: Prefer: params=multiple-objects on RPC
...
BREAKING CHANGE
A function with a JSON array or object parameter should be used instead
2023-04-04 19:55:10 -05:00
Laurence Isla and GitHub
1aed55be68
Ignore the Range header when the method is different than GET
...
fix: bug when using Range header on PATCH/DELETE
- Fix the "message": "syntax error at or near \"RETURNING\"" error
- Fix doing a limited update/delete when an order query parameter was present
breaking: The Range header is now only considered on GET requests and is ignored for any other method
- Other methods should use the `limit/offset` query parameters for sub-ranges
- PUT requests no longer return an error when this header is present
2023-04-03 10:40:25 -05:00
steve-chavez
7629eff51d
undefined-keys=apply-defaults to missing=default
2023-03-29 05:33:38 -05:00
Steve Chavez and GitHub
439a96c578
feat: undefined json keys as defaults w/ Prefer:undefined-keys
2023-03-22 02:44:14 -05:00
steve-chavez
cae1c67b00
refactor: add iPreferences to ApiRequest
...
It avoids adding a new iPrefer.. to the ApiRequest every time a
preference is added.
2023-03-09 14:40:32 -05:00
steve-chavez
be6c30a0fb
refactor: dry RPC param parsing
2023-01-18 12:26:13 -05:00
Robert and GitHub
8f80cd1469
Update nixpkgs, dependencies ( #2612 )
...
* relax upper bounds on HTTP, hspec, lens-aeson, optparse-applicative (fixes #2580 )
* upgrade stackage snapshot to latest LTS, with GHC 9.2.5
* bump nixpkgs to 2023-01-12
* fix complaints due to updated linters
2023-01-16 17:12:54 +01:00
Alexander Ljungberg and GitHub
43ad6d6aa0
feat: validate ?columns mutation targets based on schema cache ( #2542 )
...
This returns an error for trying to update or insert into invalid columns, without hitting the database. This change also switches from `json_populate_recordset` for these operations `json_to_recordset` which should make no functional difference except allowing future flexibility.
2023-01-07 22:08:30 -05:00
Laurence Isla and GitHub
5a660e0cbe
Add suggestions with fuzzy text search when no relationship is found ( #2583 )
2022-12-15 18:33:15 -05:00
steve-chavez
3773cce246
feat: null filters on embedded resources
2022-12-12 17:14:54 -05:00
steve-chavez
a5465e20d0
correct spread embed to '...'
2022-12-05 19:38:32 -05:00
Laurence Isla and GitHub
9e567216e9
feat: hint function names/parameters on error
2022-12-01 17:17:45 -05:00
Steve Chavez and GitHub
5e9dba5292
feat: Allow embedding without selecting any column ( #2574 )
2022-11-25 18:37:57 -05:00
steve-chavez
f7009635d6
test: move failed order parsing to doctest
2022-11-24 09:03:35 -05:00
steve-chavez
e5c77385ae
test: move failed or/and parsing to doctest
2022-11-24 09:03:35 -05:00
steve-chavez
3103060f4b
test: move failed json parsing to doctest
2022-11-24 09:03:35 -05:00
steve-chavez
cca0b5ae66
messages: better error for related order
2022-11-16 21:26:16 -05:00
steve-chavez
2aa0e091bb
feat: add spread embeds
2022-11-16 21:26:16 -05:00
steve-chavez
78d45b4e32
feat: add related orders
2022-11-08 17:28:50 -05:00
steve-chavez
ef42d1c87f
test: add doctest for pOrderTerm
2022-11-08 17:28:50 -05:00
Wolfgang Walther and Wolfgang Walther
e274706088
fix: Ignore leading and trailing spaces in column names, fts languages and casts
...
Fixes #2285
Signed-off-by: Wolfgang Walther <walther@technowledgy.de >
2022-10-27 21:54:44 +02:00
Wolfgang Walther and Wolfgang Walther
da632ac7d3
refactor: pIdentifierChar -> pIdentifier
...
Signed-off-by: Wolfgang Walther <walther@technowledgy.de >
2022-10-27 21:54:44 +02:00
Wolfgang Walther and Wolfgang Walther
b78b096ae4
fix: Stricter query string parsing - no empty fts lang
...
Signed-off-by: Wolfgang Walther <walther@technowledgy.de >
2022-10-27 21:54:44 +02:00
Wolfgang Walther and Wolfgang Walther
bbbc308b6f
fix: Stricter query string parsing - no empty casts
...
Signed-off-by: Wolfgang Walther <walther@technowledgy.de >
2022-10-27 21:54:44 +02:00