Re: [pgadmin-hackers] Autoformatting

Поиск
Список
Период
Сортировка
Искать
От
Robert Eckhardt
Тема
Re: [pgadmin-hackers] Autoformatting
Дата
в 17:50:58
Msg-id
CAAtBm9U4adoJW8DKQa3xBgS=au30zLPtxjSm9C21+upcxMO_8w@mail.gmail.com
Ответ на
Список
Дерево обсуждения
[pgadmin-hackers] Autoformatting Raffi Holzer <rholzer@pivotal.io>
Re: [pgadmin-hackers] Autoformatting Dave Page <dpage@pgadmin.org>
Re: [pgadmin-hackers] Autoformatting Raffi Holzer <rholzer@pivotal.io>
Re: [pgadmin-hackers] Autoformatting Dave Page <dpage@pgadmin.org>
Re: [pgadmin-hackers] Autoformatting Raffi Holzer <rholzer@pivotal.io>
Re: [pgadmin-hackers] Autoformatting Shirley Wang <swang@pivotal.io>
Re: [pgadmin-hackers] Autoformatting Dave Page <dpage@pgadmin.org>
Re: [pgadmin-hackers] Autoformatting Shirley Wang <swang@pivotal.io>
Re: [pgadmin-hackers] Autoformatting Dave Page <dpage@pgadmin.org>
Re: [pgadmin-hackers] Autoformatting Robert Eckhardt <reckhardt@pivotal.io>
Re: [pgadmin-hackers] Autoformatting Dave Page <dpage@pgadmin.org>
Re: [pgadmin-hackers] Autoformatting Robert Eckhardt <reckhardt@pivotal.io>
Re: [pgadmin-hackers] Autoformatting Dave Page <dpage@pgadmin.org>
Re: [pgadmin-hackers] Autoformatting Murtuza Zabuawala <murtuza.zabuawala@enterprisedb.com>
Re: [pgadmin-hackers] Autoformatting Jing Li <jingli@pivotal.io>
Over the weekend I created some options for formatting. certainly this isn't complete but I hope it is a good starting point for the conversation. Copy and paste lost syntax highlighting but please assume that will be included. 

/* Unformatted  */

select distinct dep.deptype,dep.classid,coalesce(coc.relname, clrw.relname) as 
ownertable from pg_depend dep left join pg_class cl on dep.objid = cl.oid 
left join pg_attribute att on dep.objid = att.attrelid and dep.objsubid = att.attnum 
where dep.objid = 16385 :: oid and classid in (select oid from pg_class 
where relname in ( 'pg_class', 'pg_constraint' )) order by classid,cl.relkin;


/* Keywords Upper, Stacked, commas after */

SELECT DISTINCT dep.deptype, 
                dep.classid, 
                Coalesce(coc.relname, clrw.relname) AS ownertable 
FROM   pg_depend dep 
       left join pg_class cl 
              ON dep.objid = cl.oid 
       left join pg_attribute att 
              ON dep.objid = att.attrelid 
                 AND dep.objsubid = att.attnum 
WHERE  dep.objid = 16385 :: oid 
       AND classid IN (SELECT oid 
                       FROM   pg_class 
                       WHERE  relname IN ( 'pg_class', 'pg_constraint' )) 
ORDER  BY classid, 
          cl.relkin; 
 
 /* Keywords Upper, Stacked, commas before */         
          
SELECT DISTINCT dep.deptype 
                ,dep.classid 
                ,Coalesce(coc.relname, clrw.relname) AS ownertable 
FROM   pg_depend dep 
       left join pg_class cl 
              ON dep.objid = cl.oid 
       left join pg_attribute att 
              ON dep.objid = att.attrelid 
                 AND dep.objsubid = att.attnum 
WHERE  dep.objid = 16385 :: oid 
       AND classid IN (SELECT oid 
                       FROM   pg_class 
                       WHERE  relname IN ( 'pg_class', 'pg_constraint' )) 
ORDER  BY classid 
          ,cl.relkin; 
          

 /* Keywords Upper, indent = 2 spaces, commas before */  

SELECT DISTINCT dep.deptype
  ,dep.classid
  ,coalesce(coc.relname, clrw.relname) AS ownertable
FROM pg_depend dep
LEFT JOIN pg_class cl
  ON dep.objid = cl.oid
LEFT JOIN pg_attribute att
  ON dep.objid = att.attrelid
    AND dep.objsubid = att.attnum
WHERE dep.objid = 16385::oid
  AND classid IN (
    SELECT oid
    FROM pg_class
    WHERE relname IN (
        'pg_class'
        ,'pg_constraint'
        )
    )
ORDER BY classid
  ,cl.relkin;
          

 /* Keywords Upper, indent = \t, commas before */  
 
SELECT DISTINCT dep.deptype
,dep.classid
,coalesce(coc.relname, clrw.relname) AS ownertable
FROM pg_depend dep
LEFT JOIN pg_class cl
ON dep.objid = cl.oid
LEFT JOIN pg_attribute att
ON dep.objid = att.attrelid
AND dep.objsubid = att.attnum
WHERE dep.objid = 16385::oid
AND classid IN (
SELECT oid
FROM pg_class
WHERE relname IN (
'pg_class'
,'pg_constraint'
)
)
ORDER BY classid
,cl.relkin; 


On Fri, May 5, 2017 at 4:38 AM, Dave Page <dpage@pgadmin.org> wrote:


On Thu, May 4, 2017 at 7:58 PM, Shirley Wang <swang@pivotal.io> wrote:
Hello!

We're starting development on this soon, so pulling this thread back up.

Here is an update on the design of the pop up, which matches the style we decided for alerts.



I like it!
 

--
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

В списке pgadmin-hackers по дате отправления
От: Dave Page
Дата:
От: Sarah McAlear
Дата:
FAQ