Unix Technical Forum

Re: [HACKERS] Dbsize backend integration

This is a discussion on Re: [HACKERS] Dbsize backend integration within the Pgsql Patches forums, part of the PostgreSQL category; --> > -----Original Message----- > From: Tom Lane [mailto:tgl@sss.pgh.pa.us] > Sent: 03 July 2005 17:10 > To: Dawid Kuroczko > ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > Pgsql Patches

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-18-2008, 12:36 AM
Dave Page
 
Posts: n/a
Default Re: [HACKERS] Dbsize backend integration



> -----Original Message-----
> From: Tom Lane [mailto:tgl@sss.pgh.pa.us]
> Sent: 03 July 2005 17:10
> To: Dawid Kuroczko
> Cc: Andreas Pflug; Dave Page; Bruce Momjian;
> PostgreSQL-patches; PostgreSQL-development
> Subject: Re: [HACKERS] [PATCHES] Dbsize backend integration
>
> Dawid Kuroczko <qnex42@gmail.com> writes:
> > Oh, I think pg_dbfile_size is best so far.

>
> I think it's by far the ugliest suggestion yet :-(


Why? It does exactly what it says on the tin! It might not be that nice,
but it does describe what it does - and noone yet has come up with
anything less ambiguous or misleading imho.

> Andreas's suggestion of having just one function with a bool parameter
> might be a workable compromise.


Aside from the fact that's a change to the API that we had settled on,
it doesn't solve the actual problem of needing a suitable name for a
function that returns the size of a table /or/ index. pg_relation_size()
or pg_table_size() can't be used for precisely the reason they were
rejected for that purpose in the first place.

Regards, Dave.

---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-18-2008, 12:36 AM
Tom Lane
 
Posts: n/a
Default Re: [HACKERS] Dbsize backend integration

"Dave Page" <dpage@vale-housing.co.uk> writes:
> Aside from the fact that's a change to the API that we had settled on,
> it doesn't solve the actual problem of needing a suitable name for a
> function that returns the size of a table /or/ index. pg_relation_size()
> or pg_table_size() can't be used for precisely the reason they were
> rejected for that purpose in the first place.


Rejected by whom? pg_relation_size is an excellent choice for that.

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 04-18-2008, 12:36 AM
Bruce Momjian
 
Posts: n/a
Default Re: [HACKERS] Dbsize backend integration

Tom Lane wrote:
> "Dave Page" <dpage@vale-housing.co.uk> writes:
> > Aside from the fact that's a change to the API that we had settled on,
> > it doesn't solve the actual problem of needing a suitable name for a
> > function that returns the size of a table /or/ index. pg_relation_size()
> > or pg_table_size() can't be used for precisely the reason they were
> > rejected for that purpose in the first place.

>
> Rejected by whom? pg_relation_size is an excellent choice for that.


We mostly tell people that table and relation are synonmous. Though
there is a distinction, it seems error-prone to rely on that distinction
in the API.

--
Bruce Momjian | http://candle.pha.pa.us
pgman@candle.pha.pa.us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073

---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://archives.postgresql.org

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 04-18-2008, 12:36 AM
Bruce Momjian
 
Posts: n/a
Default Re: [HACKERS] Dbsize backend integration

Bruce Momjian wrote:
> Tom Lane wrote:
> > "Dave Page" <dpage@vale-housing.co.uk> writes:
> > > Aside from the fact that's a change to the API that we had settled on,
> > > it doesn't solve the actual problem of needing a suitable name for a
> > > function that returns the size of a table /or/ index. pg_relation_size()
> > > or pg_table_size() can't be used for precisely the reason they were
> > > rejected for that purpose in the first place.

> >
> > Rejected by whom? pg_relation_size is an excellent choice for that.

>
> We mostly tell people that table and relation are synonmous. Though
> there is a distinction, it seems error-prone to rely on that distinction
> in the API.


I am starting to warm up to the idea of using "relation" as the combined
total. Was that the proposal? Are we prepared to make that distinction
in other places?

--
Bruce Momjian | http://candle.pha.pa.us
pgman@candle.pha.pa.us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073

---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faq

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 07:21 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
www.UnixAdminTalk.com