Re: [HACKERS] Show statistics target in \d+

2011-11-05 Thread Magnus Hagander
On Fri, Nov 4, 2011 at 16:13, Tom Lane t...@sss.pgh.pa.us wrote:
 Magnus Hagander mag...@hagander.net writes:
 Would you find it better if we showed blank (NULL) when it was -1?

 Yeah, I would.  Seems less confusing.

Adjusted per this, renamed to Stats target, and applied.


-- 
 Magnus Hagander
 Me: http://www.hagander.net/
 Work: http://www.redpill-linpro.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] Show statistics target in \d+

2011-11-04 Thread Cédric Villemain
2011/11/4 Magnus Hagander mag...@hagander.net:
 The attached patch adds a column for statistics target when viewing
 tables in psql using \d+.

 Comments/reivews?

Interesting, can the ouput be clear on the value being a default or an
explicit stat target ? (not mandatory but I believe I would like to
have it only when the stat target is jnot the default)


 --
  Magnus Hagander
  Me: http://www.hagander.net/
  Work: http://www.redpill-linpro.com/


 --
 Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
 To make changes to your subscription:
 http://www.postgresql.org/mailpref/pgsql-hackers





-- 
Cédric Villemain +33 (0)6 20 30 22 52
http://2ndQuadrant.fr/
PostgreSQL: Support 24x7 - Développement, Expertise et Formation

-- 
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] Show statistics target in \d+

2011-11-04 Thread Magnus Hagander
On Fri, Nov 4, 2011 at 14:53, Cédric Villemain
cedric.villemain.deb...@gmail.com wrote:
 2011/11/4 Magnus Hagander mag...@hagander.net:
 The attached patch adds a column for statistics target when viewing
 tables in psql using \d+.

 Comments/reivews?

 Interesting, can the ouput be clear on the value being a default or an
 explicit stat target ? (not mandatory but I believe I would like to
 have it only when the stat target is jnot the default)

It shows -1 when it's the default.

We could map that to the string default if we want, or just NULL, I
guess. Not sure which is best?

-- 
 Magnus Hagander
 Me: http://www.hagander.net/
 Work: http://www.redpill-linpro.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] Show statistics target in \d+

2011-11-04 Thread Robert Haas
On Fri, Nov 4, 2011 at 9:34 AM, Magnus Hagander mag...@hagander.net wrote:
 The attached patch adds a column for statistics target when viewing
 tables in psql using \d+.

 Comments/reivews?

Statistics doesn't seem like a very clear name for the column header.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

-- 
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] Show statistics target in \d+

2011-11-04 Thread Magnus Hagander
On Fri, Nov 4, 2011 at 15:06, Robert Haas robertmh...@gmail.com wrote:
 On Fri, Nov 4, 2011 at 9:34 AM, Magnus Hagander mag...@hagander.net wrote:
 The attached patch adds a column for statistics target when viewing
 tables in psql using \d+.

 Comments/reivews?

 Statistics doesn't seem like a very clear name for the column header.

Got any ideas for a better one? Statistics Target seemed too long to
me, and Statstarget not necessarily very user friendly?


-- 
 Magnus Hagander
 Me: http://www.hagander.net/
 Work: http://www.redpill-linpro.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] Show statistics target in \d+

2011-11-04 Thread Robert Haas
On Fri, Nov 4, 2011 at 10:09 AM, Magnus Hagander mag...@hagander.net wrote:
 On Fri, Nov 4, 2011 at 15:06, Robert Haas robertmh...@gmail.com wrote:
 On Fri, Nov 4, 2011 at 9:34 AM, Magnus Hagander mag...@hagander.net wrote:
 The attached patch adds a column for statistics target when viewing
 tables in psql using \d+.

 Comments/reivews?

 Statistics doesn't seem like a very clear name for the column header.

 Got any ideas for a better one? Statistics Target seemed too long to
 me, and Statstarget not necessarily very user friendly?

I would prefer Stats Target to Statistics, because I think it's more clear.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

-- 
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] Show statistics target in \d+

2011-11-04 Thread Josh Kupershmidt
On Fri, Nov 4, 2011 at 10:05 AM, Magnus Hagander mag...@hagander.net wrote:
 On Fri, Nov 4, 2011 at 14:53, Cédric Villemain
 Interesting, can the ouput be clear on the value being a default or an
 explicit stat target ? (not mandatory but I believe I would like to
 have it only when the stat target is jnot the default)

 It shows -1 when it's the default.

 We could map that to the string default if we want, or just NULL, I
 guess. Not sure which is best?

I thought -1 was just fine. The ALTER TABLE doc page is clear that -1
means the system default, and having another value may just confuse
users.

Josh

-- 
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] Show statistics target in \d+

2011-11-04 Thread Stephen Frost
* Magnus Hagander (mag...@hagander.net) wrote:
 On Fri, Nov 4, 2011 at 15:06, Robert Haas robertmh...@gmail.com wrote:
  Comments/reivews?
 
  Statistics doesn't seem like a very clear name for the column header.
 
 Got any ideas for a better one? Statistics Target seemed too long to
 me, and Statstarget not necessarily very user friendly?

I don't think we need to kill ourselves over making it super
user-friendly.  If they don't know what it is/means, they can go read
the docs. :)  I agree w/ Robert that 'Statistics' is a bad name.  I'd
suggest 'stat_target'.

Thanks,

Stephen


signature.asc
Description: Digital signature


Re: [HACKERS] Show statistics target in \d+

2011-11-04 Thread Kevin Grittner
Magnus Hagander mag...@hagander.net wrote:
 
  Interesting, can the ouput be clear on the value being a default
 or an explicit stat target ? (not mandatory but I believe I would
 like to have it only when the stat target is jnot the default)
 
 It shows -1 when it's the default.
 
 We could map that to the string default if we want, or just
 NULL, I guess. Not sure which is best?
 
I think it would be most useful for it to show as blank, so that
overrides stand out.  NULL seems the best way to do that.
 
-Kevin

-- 
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] Show statistics target in \d+

2011-11-04 Thread Cédric Villemain
2011/11/4 Josh Kupershmidt schmi...@gmail.com:
 On Fri, Nov 4, 2011 at 10:05 AM, Magnus Hagander mag...@hagander.net wrote:
 On Fri, Nov 4, 2011 at 14:53, Cédric Villemain
 Interesting, can the ouput be clear on the value being a default or an
 explicit stat target ? (not mandatory but I believe I would like to
 have it only when the stat target is jnot the default)

 It shows -1 when it's the default.

 We could map that to the string default if we want, or just NULL, I
 guess. Not sure which is best?

 I thought -1 was just fine. The ALTER TABLE doc page is clear that -1
 means the system default, and having another value may just confuse
 users.

yes, it looks good to me.


 Josh




-- 
Cédric Villemain +33 (0)6 20 30 22 52
http://2ndQuadrant.fr/
PostgreSQL: Support 24x7 - Développement, Expertise et Formation

-- 
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] Show statistics target in \d+

2011-11-04 Thread Tom Lane
Magnus Hagander mag...@hagander.net writes:
 The attached patch adds a column for statistics target when viewing
 tables in psql using \d+.

 Comments/reivews?

Isn't this going to show -1 most of the time?  Seems rather useless,
not to mention confusing to people who don't know what that means.

regards, tom lane

-- 
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] Show statistics target in \d+

2011-11-04 Thread Magnus Hagander
On Fri, Nov 4, 2011 at 15:23, Tom Lane t...@sss.pgh.pa.us wrote:
 Magnus Hagander mag...@hagander.net writes:
 The attached patch adds a column for statistics target when viewing
 tables in psql using \d+.

 Comments/reivews?

 Isn't this going to show -1 most of the time?  Seems rather useless,
 not to mention confusing to people who don't know what that means.

It will, but in the cases where it doesn't, it'll be very useful and
good to have thrown in your face.

Would you find it better if we showed blank (NULL) when it was -1?


-- 
 Magnus Hagander
 Me: http://www.hagander.net/
 Work: http://www.redpill-linpro.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] Show statistics target in \d+

2011-11-04 Thread Tom Lane
Magnus Hagander mag...@hagander.net writes:
 Would you find it better if we showed blank (NULL) when it was -1?

Yeah, I would.  Seems less confusing.

regards, tom lane

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers