-
-
Notifications
You must be signed in to change notification settings - Fork 208
It should not throw 404 error with message of "not found". >>> (Regarding "Updating data returns an empty Exception when there is no results returned #87") #315
New issue
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
Comments
For example, when I have the major table for the basic data (e.g. customers.customerId and customers.name) and then I have the relative table (orders) for the detail data (e.g. orders.numer, orders.customerId (foreign key relate to customer.customerId) ...) ...etc. It is not necessary that I have to check table (orders) every time when I found I mis-typed the customers.customerId data and try to update customers table and orders table (maybe there were many records in orders table with the mis-typed the customers.customerId, or there is none in orders table using the wrong customers.customerId. I just want to update the customer table with the correct customers.customerId and update the orders table at the same time, even if the wrong customers.customerId data has not been created in the orders table. ) Because you don’t know if the order table has Relevant data, using a relational database, you must update the associated tables and data. It is not necessary to use the query command to check whether the data has been saved before modifying the data every time. This should be judged and processed by the SQL Update command. For your information. Jason |
not found
now, which is the expected behavior of Postgrest when there are no rows to update, so closing this PR as it's resolved!
@dshukertjr |
@JasonChiu-dev you are saying that it should just return an empty array without throwing an error, correct? supabase-flutter is just reflecting what Postgrest returns us, so you might want to open an issue there for this. |
Hi Tyler,
Yes, it should just return an empty array without throwing an error. My
apps (with Supabase support) already running for a period of time, the
Supabase react very well.
My customer recently reported that the app was not working properly, and I
checked and found that it is the problem I reported and mentioned.
In the past, I used supabase-dart and work correctly. Recently, I changed the supabase package from supabase-dart
to supabase-flutter. Could it be that Supabase has been modified after the
updated version to cause this problem?
Finally, it should just return an empty array without throwing an error.
Best,
Jason
Tyler ***@***.***> 於 2022年12月23日 週五 16:53 寫道:
… @JasonChiu-dev <https://github.com/JasonChiu-dev> you are saying that it
should just return an empty array without throwing an error, correct?
supabase-flutter is just reflecting what Postgrest returns us, so you
might want to open an issue there for this.
—
Reply to this email directly, view it on GitHub
<#315 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ATPEA2GBYSKQWG2HE5WMD6TWOVR7LANCNFSM6AAAAAATHOLHMA>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
@JasonChiu-dev Will fix this and ship an update ASAP! |
Great, thanks!
Best,
Jason
Tyler ***@***.***>於 2022年12月23日 週五,下午8:34寫道:
… @JasonChiu-dev <https://github.com/JasonChiu-dev>
Actually, I was wrong, and the js client library does have a mechanism to
ignore 404 errors.
supabase/postgrest-js#295
<supabase/postgrest-js#295>
Will fix this and ship an update ASAP!
—
Reply to this email directly, view it on GitHub
<#315 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ATPEA2CRPOFWQZTADJLG3BLWOWL3ZANCNFSM6AAAAAATHOLHMA>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
@JasonChiu-dev |
|
@JasonChiu-dev Will follow up on the support ticket. |
@JasonChiu-dev You can check your postgrest version as described here. If you have a version >= v10.1.0, the 404 error on update should not happen. |
This is correct. When I followed the supabase support team's guidance: "if you pause & restore your project, this will upgrade the PostgREST version, many of the Postgres extensions and Postgres to version 15. Now, my project upgrade to the PostgREST version 10.1.1 and the 404 error on update do not happen. I appreciated. |
Originally posted by @dshukertjr in #87 (comment)
It is so strange to throws 404 error with message of not found!!
On SQL command test, if the data is not found when doing "update" action, the SQL response "Success. No rows returned". It should not throws 404 error with message of not found.
The text was updated successfully, but these errors were encountered: