Re: [GENERAL] Odd behavior in functions w/ anyarray & anyelement

2013-11-09 Thread David Johnston
Tom Lane-2 wrote > Furthermore, if there are positions declared anyarray > and others declared anyelement, the actual array type in the anyarray > positions must be an array whose elements are the same type appearing in > the anyelement positions. > > The last sentence is what I was saying

Re: [GENERAL] Odd behavior in functions w/ anyarray & anyelement

2013-11-09 Thread Tom Lane
David Johnston writes: > Tom Lane-2 wrote >> you do have one conceptual error: anyarray to anyelement is supposed >> to return the element type of the input array type. So when you pass >> TEXT[] to this function, the SQL parser decides that the expected >> result type is TEXT. > While this is

Re: [GENERAL] Odd behavior in functions w/ anyarray & anyelement

2013-11-09 Thread David Johnston
Tom Lane-2 wrote > you do have one conceptual error: anyarray to anyelement is supposed > to return the element type of the input array type. So when you pass > TEXT[] to this function, the SQL parser decides that the expected > result type is TEXT. While this is how it behaves in practice I di

Re: [GENERAL] Odd behavior in functions w/ anyarray & anyelement

2013-11-09 Thread Tom Lane
[ slowly catching up on vacation email ] Joshua Burns writes: > From that point I wrote a bunch of simply anyarray/element related > functions to better understand how these pseudo-types behave, which has > left me more confused than when I started. I think you would have been less confused if y

Re: [GENERAL] new line in psotgres

2013-11-09 Thread John R Pierce
On 11/9/2013 5:33 PM, Gavin Flower wrote: I redid the above, and included at test with 'E' & '\n' - just one slash before the 'n'. The other changes are mostly cosmetic. E'\\n' would be required if you were entering the string in a programming language that itself used \ as an esc

Re: [GENERAL] new line in psotgres

2013-11-09 Thread Gavin Flower
On 10/11/13 09:18, Gavin Flower wrote: On 10/11/13 02:38, Alban Hertroys wrote: On Nov 9, 2013, at 12:08, abdullatheef wrote: >you can include newline in postgre using literal E > >create table table (text varchar(50)); >insert into Table (text) values (E'This is the first part \\n And this i

Re: [GENERAL] Query runs forever after upgrading to 9.3

2013-11-09 Thread Tom Lane
"Andrus" writes: >> Just out of curiosity, what "earlier version" was that that was able to >> run this query quickly? > It was installed in customer site at May 2012 in Windows 2003 server and > latest RTM version of Postgres > x32 in this time was used. That would probably have been 9.1.someth

Re: [GENERAL] Query runs forever after upgrading to 9.3

2013-11-09 Thread Andrus
Hi, Just out of curiosity, what "earlier version" was that that was able to run this query quickly? It was installed in customer site at May 2012 in Windows 2003 server and latest RTM version of Postgres x32 in this time was used. In this year server was upgraded to Windows 2008 x64 server an

Re: [GENERAL] new line in psotgres

2013-11-09 Thread Gavin Flower
On 10/11/13 02:38, Alban Hertroys wrote: On Nov 9, 2013, at 12:08, abdullatheef wrote: >you can include newline in postgre using literal E > >create table table (text varchar(50)); >insert into Table (text) values (E'This is the first part \\n And this is >the second'); Or like this: developm

Re: [GENERAL] what could cause postgres to crash?

2013-11-09 Thread Sandeep Gupta
Dear Scott, Thanks for the input. I doubt that the system has any scripts to kill idle connections but I would double check that. There are two difficulty in tracing and fixing this: 1) The crash is predictable and 2) Can find any killed in the kernel log files. There are few materials on the ne

Re: [GENERAL] what could cause postgres to crash?

2013-11-09 Thread Scott Marlowe
On Fri, Nov 8, 2013 at 8:16 PM, Sandeep Gupta wrote: > Hi, > > My postgres sessions, after being idle for 5 --6 hrs, crash on their own. > Sometimes with error messages sometimes without. The message I get appended > below. I was looking for suggestion to narrow down as to what could have > cause

Re: [GENERAL] Query runs forever after upgrading to 9.3

2013-11-09 Thread Tom Lane
"Andrus" writes: > Query > SELECT * FROM toode > WHERE toode in (SELECT toode FROM tempkaive) > OR toode in (SELECT toode FROM tempalgsemu) > stops working after upgrading to 9.3 RTM in Windows from earlier version. Just out of curiosity, what "earlier version" was that that was able to run

Re: [GENERAL] new line in psotgres

2013-11-09 Thread Alban Hertroys
On Nov 9, 2013, at 12:08, abdullatheef wrote: > you can include newline in postgre using literal E > > create table table (text varchar(50)); > insert into Table (text) values (E'This is the first part \\n And this is > the second'); Or like this: development=> begin; BEGIN development=> creat

Re: [GENERAL] new line in psotgres

2013-11-09 Thread abdullatheef
you can include newline in postgre using literal E create table table (text varchar(50)); insert into Table (text) values (E'This is the first part \\n And this is the second'); -- View this message in context: http://postgresql.1045698.n5.nabble.com/new-line-in-psotgres-tp1885914p5777583.html

Re: [GENERAL] Documents/ppts/pdfs

2013-11-09 Thread Jayadevan M
> These presentations are available in > http://www.postgresql.org/developer/coding/ > > Presentations > >- Transaction Processing in > PostgreSQL (From >OSDN Oct 2000) >- A Tour of PostgreSQL > Internals

Re: [GENERAL] Documents/ppts/pdfs

2013-11-09 Thread Raghu Ram
On Sat, Nov 9, 2013 at 12:53 PM, Jayadevan M wrote: > Hi, > > When I search for material on PostgreSQL, once in a while I see reasonably > old, but very good content in file such as > http://www.postgresql.org/files/developer/transactions.pdf > How can I browse to a top level folder ( > http://www