页面树结构

版本比较

标识

  • 该行被添加。
  • 该行被删除。
  • 格式已经改变。

状态
subtletrue
colourGreen
titleSince v1.3.0

注意

You need to Database Connection Configuration to be able to retrieve data from correct database. 

Steps

  1. Create a new Confluence page or edit an existing Confluence page
  2. Insert SVG Chart Macro
  3. Insert a code block macro inside the SVG Chart Macro
  4. Edit the code block macro and choose SQL in the syntax highlighting field. (Currently only support SQL query statement starting with select )

  5. Edit the code block macro, fill in the database name into the title field of code block macro. If the database name is not provided, the first available database will be used. 


SQL Example

Issue count group by Project and Issuetype:

代码块
languagesql
titleConfluence
select s.spacename as "Space Name",count(case when contenttype='PAGE' then contenttype else null end) as "Page", count(case when contenttype='ATTACHMENT' and prevver is null then contenttype else null end) as "Attachment", count(case when contenttype='BLOGPOST' then contenttype else null end) as "Blog" from CONTENT c join SPACES s on c.spaceid=s.spaceid JOIN SPACEPERMISSIONS sp ON s.spaceid=sp.spaceid where sp.PERMALLUSERSSUBJECT is null and sp.PERMGROUPNAME is null and sp.PERMUSERNAME is null and c.CONTENT_STATUS='current' group by s.spacename;



Svg chart macro
subTitleconfluence.unlimax.com
chartTypedonut
showTabletrue
titleConfluence Pages Statistics By Spaces
代码块
languagesql
titleconfluence
select s.spacename as "Space Name",count(case when contenttype='PAGE' then contenttype else null end) as "Page", count(case when contenttype='ATTACHMENT' and prevver is null then contenttype else null end) as "Attachment", count(case when contenttype='BLOGPOST' then contenttype else null end) as "Blog" from CONTENT c join SPACES s on c.spaceid=s.spaceid JOIN SPACEPERMISSIONS sp ON s.spaceid=sp.spaceid where sp.PERMALLUSERSSUBJECT is null and sp.PERMGROUPNAME is null and sp.PERMUSERNAME is null and c.CONTENT_STATUS='current' group by s.spacename;