Unix Technical Forum

Re: Proposed Patchs

This is a discussion on Re: Proposed Patchs within the pgsql Interfaces Pgadmin Support forums, part of the PostgreSQL category; --> > -----Original Message----- > From: Thomas Sondag [mailto:thomas.sondag@gmail.com] > Sent: 29 May 2006 10:02 > To: Dave Page > ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Interfaces Pgadmin Support

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-17-2008, 08:26 PM
Dave Page
 
Posts: n/a
Default Re: Proposed Patchs



> -----Original Message-----
> From: Thomas Sondag [mailto:thomas.sondag@gmail.com]
> Sent: 29 May 2006 10:02
> To: Dave Page
> Cc: pgadmin-support@postgresql.org
> Subject: Re: [pgadmin-support] Proposed Patchs
>
> Hum, I miss this option ... sorry, but the main difference with the
> current behaviour is for object owning. The main idea was to set
> object owner to a group like that :
> database foo -> group foo
> schema bar -> group bar
> schema bar read user -> user toto
>
> I don't know if that's a good policy, but this case may exist, we may
> add an option like "Show Group for object owning" ?


Yes, that seems like a much better option - though I wonder if it should
default to just groups and then use the existing setting as per the
permissions. That would seem more consistent.

> The last bug I have is for database creation, I don't know how to get
> the current login.


Well dlgDatabase will automatically use the parent node's database (ie.
The maintenance DB) when appropriate so you should just be able to get
the username from that.

From dlgDatabase.cpp

dlgProperty *pgDatabaseFactory::CreateDialog(frmMain *frame, pgObject
*node, pgObject *parent)
{
dlgDatabase *dlg=new dlgDatabase(this, frame, (pgDatabase*)node);
if (dlg && !node)
{
// use the server's connection to avoid "template1 in use"
dlg->connection=parent->GetConnection();
}
return dlg;
}

Regards, Dave.

---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-17-2008, 08:26 PM
Thomas Sondag
 
Posts: n/a
Default Re: Proposed Patchs

2006/5/29, Dave Page <dpage@vale-housing.co.uk>:
>
>
> > -----Original Message-----
> > From: Thomas Sondag [mailto:thomas.sondag@gmail.com]
> > Sent: 29 May 2006 10:02
> > To: Dave Page
> > Cc: pgadmin-support@postgresql.org
> > Subject: Re: [pgadmin-support] Proposed Patchs
> >
> > Hum, I miss this option ... sorry, but the main difference with the
> > current behaviour is for object owning. The main idea was to set
> > object owner to a group like that :
> > database foo -> group foo
> > schema bar -> group bar
> > schema bar read user -> user toto
> >
> > I don't know if that's a good policy, but this case may exist, we may
> > add an option like "Show Group for object owning" ?

>
> Yes, that seems like a much better option - though I wonder if it should
> default to just groups and then use the existing setting as per the
> permissions. That would seem more consistent.
>


I'm not sure this is the better way, because most of the time objects
are owned by the current user, so showing only group by default can be
a bit confusing.

If you want to see the result with the "Show group ..." option try
the folowing patch . the main idea for AddRoles function was to remove
one sql query.

I test this patch only with postgresql 8.1 and it stop segfaulting now


Thomas

---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
choose an index scan if your joining column's datatypes do not
match

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 10:53 AM.


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