Re: [GENERAL] Difference between varchar and text?

2012-11-18 Thread John R Pierce
On 11/17/12 11:48 PM, Abel Abraham Camarillo Ojeda wrote: As far as I know varchar(n) with n being less or equal than 126 cannot be toasted, and have only one octet of overhead. http://www.postgresql.org/docs/9.2/static/storage-toast.html the same is true for varchar(n) with larger values of N

Re: [GENERAL] user aggregate function ( calculate the average value of each index of an array column )

2012-11-18 Thread Vincent Veyron
Le jeudi 15 novembre 2012 à 19:10 +0100, Myoung-Ah KANG a écrit : > > > I have a table with several lines as following; > > > > - Create table mytable (type number , values integer [2]) ; > > > > - Insert into mytable values (1, ‘{ 10, 0 }’ ); > > - Insert

Re: [GENERAL] PG_TERMINATE_BACKEND not working.

2012-11-18 Thread Craig Ringer
On 11/16/2012 02:34 PM, Harry wrote: > I am facing problem i.e. connections after execution completed are residing > in pg_stat_activity and pg_stat_database. > but when i am trying to kill them manually using pg_terminate_backend (All > IDLE connections are getting killed but, others like declare,

Re: [GENERAL] PG_TERMINATE_BACKEND not working.

2012-11-18 Thread Chris Angelico
On Sun, Nov 18, 2012 at 10:25 PM, Craig Ringer wrote: > On 11/16/2012 02:34 PM, Harry wrote: >> I am facing problem i.e. connections after execution completed are residing >> in pg_stat_activity and pg_stat_database. >> but when i am trying to kill them manually using pg_terminate_backend (All >>

Re: [GENERAL] [BUGS] Prepared Statement Name Truncation

2012-11-18 Thread David Johnston
On Nov 18, 2012, at 2:24, Tom Lane wrote: > "Greg Sabino Mullane" writes: >>> If it's a postgres bug, what is the fix? Make the identifier max size >>> longer? > >> I'd also be in favor of this, in addition to upgrading from a NOTICE. > > On the whole I'm not too excited about changing this. >

Re: [GENERAL] Difference between varchar and text?

2012-11-18 Thread Vick Khera
On Sun, Nov 18, 2012 at 2:29 AM, Tom Lane wrote: > I'd generally recommend using "text" if you don't have any interest in > enforcing a specific length limit. > Will there be any table re-writing if I do an alter to change the column type from varchar(N) to text? I have some really old (from 20

Re: [GENERAL] [BUGS] Prepared Statement Name Truncation

2012-11-18 Thread Gavan Schneider
On Sunday, November 18, 2012 at 01:10, David Johnston wrote: > > Can the system be made smart enough to not allow intra-schema > collisions in addition to same schema ones? That would seem to be the > area of greatest concern - particularly around the usage of > truncate/delete/drop. > > My su

Re: [GENERAL] [HACKERS] Parser - Query Analyser

2012-11-18 Thread Craig Ringer
On 11/18/2012 09:57 PM, Michael Giannakopoulos wrote: > Hi guys, > > Thanks for your answers. Yes, what I meant is to create a function > that takes as an input rows of a specific relation, does something and > returns as an output rows with different attributes. I am > experimenting right now with

Re: [GENERAL] Difference between varchar and text?

2012-11-18 Thread Craig Ringer
On 11/19/2012 12:57 AM, Vick Khera wrote: > > > On Sun, Nov 18, 2012 at 2:29 AM, Tom Lane > wrote: > > I'd generally recommend using "text" if you don't have any interest in > enforcing a specific length limit. > > > Will there be any table re-writing if I do an

Re: [GENERAL] Difference between varchar and text?

2012-11-18 Thread Vick Khera
On Sun, Nov 18, 2012 at 7:24 PM, Craig Ringer wrote: > On 11/19/2012 12:57 AM, Vick Khera wrote: > > > > On Sun, Nov 18, 2012 at 2:29 AM, Tom Lane wrote: > >> I'd generally recommend using "text" if you don't have any interest in >> enforcing a specific length limit. >> > > Will there be any t

Re: [GENERAL] Difference between varchar and text?

2012-11-18 Thread Jeff Janes
On Sun, Nov 18, 2012 at 4:35 PM, Vick Khera wrote: > On Sun, Nov 18, 2012 at 7:24 PM, Craig Ringer wrote: >> >> On 11/19/2012 12:57 AM, Vick Khera wrote: >> >> >> >> On Sun, Nov 18, 2012 at 2:29 AM, Tom Lane wrote: >>> >>> I'd generally recommend using "text" if you don't have any interest in >>

Re: [GENERAL] Difference between varchar and text?

2012-11-18 Thread Tom Lane
Jeff Janes writes: > On Sun, Nov 18, 2012 at 4:35 PM, Vick Khera wrote: >> On Sun, Nov 18, 2012 at 7:24 PM, Craig Ringer wrote: >>> That depends on the PostgreSQL version. Some changes were made to improve >>> that recently; from memory, it used to require rewriting, so people would >>> sometime

[GENERAL] Fuzzystrmatch contrib module on RHEL63

2012-11-18 Thread Ike Nnabugwu
I am building an rpm package fuzzystrmatch to be installed on RHEL63 but I do not know where to get the modules for it.I will appreciate any pointers that will assist with this task. -- Ike Nnabugwu

Re: [GENERAL] Fuzzystrmatch contrib module on RHEL63

2012-11-18 Thread Peter Geoghegan
On 19 November 2012 02:13, Ike Nnabugwu wrote: > I am building an rpm package fuzzystrmatch to be installed on RHEL63 but I > do not know where to get the modules for it.I will appreciate any pointers > that will assist with this task. Do you mean that you need to install fuzzystrmatch? I think

[GENERAL] EDB installer should check for valid %COMSPEC%

2012-11-18 Thread Craig Ringer
Hi folks Some recent discussion on Stack Overflow has revealed another exciting way for Windows computers to be subtly broken. For as yet unknown reasons - probably related to security/virus scanner software, since everything else seems to be - some Windows machines have an invalid COMSPEC enviro

[GENERAL] Full text search in Chinese

2012-11-18 Thread Christian Jensen
Can anyone shed any light on how I might go about implementing full text search for Chinese? I have heard I need to go down the NGRAM route but would love to get some external feedback. Our application has a per user 'ignore' list that we 'left outer join where null' sort of deal on so I really r

Re: [GENERAL] How to list all schema names inside a PostgreSQL database through SQL

2012-11-18 Thread Xiaobo Gu
Thanks a lot. On Fri, Nov 16, 2012 at 5:33 AM, Ondrej Ivanič wrote: > Hi, > > On 15 November 2012 23:31, Xiaobo Gu wrote: >> How can I list all schema names inside a PostgreSQL database through >> SQL, especially thoese without any objects created inside it. > > Use -E psql's option: > -E, --

Re: [GENERAL] How to list all schema names inside a PostgreSQL database through SQL

2012-11-18 Thread Xiaobo Gu
Thanks a lot. On Fri, Nov 16, 2012 at 5:33 AM, Ondrej Ivanič wrote: > Hi, > > On 15 November 2012 23:31, Xiaobo Gu wrote: >> How can I list all schema names inside a PostgreSQL database through >> SQL, especially thoese without any objects created inside it. > > Use -E psql's option: > -E, --