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
Implement UPDATE OR INSERT INTO SELECT [CORE2447] #2861
Comments
Commented by: Sean Leyne (seanleyne) IMHO, this is "nice to have". The "EXECUTE BLOCK" functionality already allows a user/developer to construct a simple structure/statement to perform this task. |
Commented by: @hvlad is it different from already implemented MERGE statement ? |
Commented by: Cosmin Apreutesei (cosmin_ap2) Oh, and before you trash this (again), you should be informed that MERGE sucks. That ridiculous "natural-language-like" syntax of the 60s frenzy will always be a copy-paste deal to me since I could never remember that arbitrary sequence of keywords to construct such command. Oh my. |
Commented by: @asfernandes This is already rejected many times, as nobody put a good argument for it. Your one about don't remember the syntax is the greatest one I hear. UPDATE OR INSERT exists for the use-case of common task as make changes for *one* record, like many applications and ORM frameworks does. To manipulate a set of records use MERGE. PS: I don't think an extension to the command will defeat it. I just think such feature request is very low priority, because it's already covered by another command. |
Modified by: @asfernandespriority: Major [ 3 ] => Minor [ 4 ] |
Commented by: @hvlad Sorry, i see zero reasons to add non-standard questionable syntax for already implemented standard feature. |
Commented by: Cosmin Apreutesei (cosmin_ap2) I'd be happy to throw in some arguments, but first I need some clues as to what makes a good argument for you guys. I'm a little puzzled since a few arguments that I consider good enough, were already rejected, for example: Btw, why is the syntax questionable? Just because it's non-standard, or there are other reasons too? |
Commented by: @asfernandes MATCHING after "SELECT ..." is something I feel is horrible... It neither can be before it. And for the feature request, just think about it. You liking or not, the standard is there, and DBMS implements parts of it, and people can learn one thing and generally apply it everywhere. And that happens with MERGE. On the other hand, we designed UPDATE OR INSERT and is easy for us to extend it. But there should be a good reason for it. The SELECT part were not forgotten at design time, it was just something taken away. Note also that some people already request UPDATE with multiple tables, which is also MERGE. If we do every request just because an user or another wants, we'll have a bloated product. PS: Seems you feel from your comments we're here to reject your ideas. If you follow FB lists, you see how many of our own ideas were just rejected by others and community in general. |
Commented by: @hvlad Cosmin, > - the simple fact that this was already requested several times is an indication that this might just be what users need (if you care about that aspect of course) -- unless their requests are silly or unfeasible yes, people need *functionality* (not a *syntax*), and when pointed to MERGE they are satisfied > it's you who should give a good argument against them > about MERGE, I wasn't complaining about my short memory, but the silly syntax no one want to use > would you ever have considered implementing it ? > Btw, why is the syntax questionable ? Adriano, |
Modified by: @pcisarstatus: Resolved [ 5 ] => Closed [ 6 ] |
Submitted by: Cosmin Apreutesei (cosmin_ap2)
Votes: 1
Syntax: UPDATE OR INSERT INTO (col_list) select_clause [matching_clause] [returning_clause]
The text was updated successfully, but these errors were encountered: