Re: [HACKERS] on existing update construct
On 05/16/2013 02:44 AM, Dev Kumkar wrote: Hello, Is there an alternative of Sybase on existing update construct in pgsql. No. See: http://www.depesz.com/2012/06/10/why-is-upsert-so-complicated/ -- Craig Ringer http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training Services -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
[HACKERS] on existing update construct
Hello, Is there an alternative of Sybase on existing update construct in pgsql. ON DUPLICATE KEY UPDATE doesn't work. Thanks in advance! Regards - Dev
Re: [HACKERS] on existing update construct
On Wed, May 15, 2013 at 11:44 AM, Dev Kumkar devdas.kum...@gmail.com wrote: Hello, Is there an alternative of Sybase on existing update construct in pgsql. ON DUPLICATE KEY UPDATE doesn't work. Thanks in advance! No, you'll have to either handle this in the application or use a stored procedure at this time. The omission of such a construct from psql's \h command and the manual is not in error. -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
Re: [HACKERS] on existing update construct
Well ya, stored procedure also was thinking about pre-insert trigger. Am sure folks here must have gone thru this and had alternatives. Also was reading about merge_by_key. On Wed, May 15, 2013 at 12:51 PM, Daniel Farina dan...@heroku.com wrote: On Wed, May 15, 2013 at 11:44 AM, Dev Kumkar devdas.kum...@gmail.com wrote: Hello, Is there an alternative of Sybase on existing update construct in pgsql. ON DUPLICATE KEY UPDATE doesn't work. Thanks in advance! No, you'll have to either handle this in the application or use a stored procedure at this time. The omission of such a construct from psql's \h command and the manual is not in error.
Re: [HACKERS] on existing update construct
On 05/15/2013 02:22 PM, Dev Kumkar wrote: Well ya, stored procedure also was thinking about pre-insert trigger. Am sure folks here must have gone thru this and had alternatives. Also was reading about merge_by_key. It's been on the TODO list forever. It's harder to implement well than you would think. -- Josh Berkus PostgreSQL Experts Inc. http://pgexperts.com -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
Re: [HACKERS] on existing update construct
Please do not top-post on the PostgreSQL lists. See http://idallen.com/topposting.html Also, note that pgsql-hackers is entirely the wrong list for this sort of question. You should have been asking on pgsql-general. Apologies for top-post! Well I thought pgsql-hackers will suggest some new solution was just going by the description of mailing-list. Its worth looking into http://stackoverflow.com/questions/1109061/insert-on-duplicate-update-postgresql Let me know and I will post this question on pgsql-general. It's been on the TODO list forever. It's harder to implement well than you would think. Yes, I think it be nice to see this in one of the upcoming releases. Thanks!
Re: [HACKERS] on existing update construct
Basically I was referring to this link http://mbk.projects.postgresql.org Any suggestions here? Thanks!