Re: [GENERAL]

2013-07-14 Thread Vincenzo Romano
2013/7/15 Luca Ferrari : > On Sun, Jul 14, 2013 at 8:36 PM, Vincenzo Romano > wrote: > >> I am only concerned about how late is done the binding between a table >> name and the actual OID for other functions, views and triggers. > > > Well, it should work like this: once the parser decides that a

Re: [GENERAL] Transaction control in shards through PLPROXY

2013-07-14 Thread Sergey Konoplev
On Sun, Jul 14, 2013 at 10:56 PM, Granthana Biswas wrote: > Thank you for your reply. Have you implemented this while sharding your > database? Did it cause any performance issues? I used it for just several mission critical featured in one project, not widely. What about performance issues - it

Re: [GENERAL]

2013-07-14 Thread Luca Ferrari
On Sun, Jul 14, 2013 at 8:36 PM, Vincenzo Romano wrote: > I am only concerned about how late is done the binding between a table > name and the actual OID for other functions, views and triggers. Well, it should work like this: once the parser decides that a query looks good, it seaches for the

Re: [GENERAL] Transaction control in shards through PLPROXY

2013-07-14 Thread Sergey Konoplev
On Wed, Jul 10, 2013 at 10:20 PM, Granthana Biswas wrote: > Inspite of being aware that PLPROXY does autocommit for DML functions called > on shards, I was wondering if there is any way around to put a set of DML > functions called from Router on shards inside a transaction so that all > updates o

Re: [GENERAL] Build RPM from Postgres Source

2013-07-14 Thread ktewari1
Thanks for your reply. I will take a look. Kul. -- View this message in context: http://postgresql.1045698.n5.nabble.com/Build-RPM-from-Postgres-Source-tp5763633p5763746.html Sent from the PostgreSQL - general mailing list archive at Nabble.com. -- Sent via pgsql-general mailing list (pgsq

Re: [GENERAL] Return cols and rows via stored procedure

2013-07-14 Thread David Johnston
Robert James wrote > I'd like a stored procedure which does something like: > > INSERT INTO... > SELECT... -- This should be returned as multicolumn, multifield - just > like a table or view > > When I run it, though, instead of getting a table, I get one field > with all the data in it as a comp

[GENERAL] Return cols and rows via stored procedure

2013-07-14 Thread Robert James
I'd like a stored procedure which does something like: INSERT INTO... SELECT... -- This should be returned as multicolumn, multifield - just like a table or view When I run it, though, instead of getting a table, I get one field with all the data in it as a compound type. I'd like to return the

Re: [GENERAL] Update big table

2013-07-14 Thread BladeOfLight16
I don't believe you can use JOIN explicitly in this situation because it's an UPDATE, but I believe you can accomplish the same effect with FROM and WHERE. UPDATE table SET column1 = TRUE FROM table2 WHERE table1.event_id = table2.event_id; I would make sure there's an index on table2.event_id if

Re: [GENERAL]

2013-07-14 Thread Vincenzo Romano
2013/7/14 Luca Ferrari : > On Fri, Jul 12, 2013 at 1:23 PM, Vincenzo Romano > wrote: >> Hi all >> I'm making some experiments with table archiving and I'd like to >> "replace" a full table F with an empty one E. >> In order to do this I see only one way: >> >> ALTER TABLE F RENAME TO T; >> ALTER T

Re: [GENERAL]

2013-07-14 Thread Luca Ferrari
On Fri, Jul 12, 2013 at 1:23 PM, Vincenzo Romano wrote: > Hi all > I'm making some experiments with table archiving and I'd like to > "replace" a full table F with an empty one E. > In order to do this I see only one way: > > ALTER TABLE F RENAME TO T; > ALTER TABLE E RENAME TO F; > ALTER TABLE T

[GENERAL] Re: Syntax error at or near “on”

2013-07-14 Thread Alexander Farber
Nevermind, got the answer here: http://stackoverflow.com/questions/17638774/syntax-error-at-or-near-on -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] Syntax error at or near “on”

2013-07-14 Thread Alexander Farber
Hello! In PostgreSQL 8.4.13 why do I please get the syntax error ERROR: syntax error at or near "on" LINE: ... references balkan_users(id) check (id <> author) on delete ... for the following 2 statements? create table balkan_users ( id varchar(32) primary key, first_name varch

Re: [GENERAL] Update big table

2013-07-14 Thread Vincenzo Romano
2013/7/14 Haiming Zhang : > Hi All, > > > > I am using postgres 9.1, I have a question about updating big table. Here is > the basic information of this table. > > 1. This table has one primary key and other 11 columns. > > 2. It also has a trigger that before updat

[GENERAL] Update big table

2013-07-14 Thread Haiming Zhang
Hi All, I am using postgres 9.1, I have a question about updating big table. Here is the basic information of this table. 1. This table has one primary key and other 11 columns. 2. It also has a trigger that before update records, another table got updated first.