SINCE V1.3.0
You need to Database Connection Configuration to be able to retrieve data from correct database.
Steps
- Create a new Confluence page or edit an existing Confluence page
- Insert SVG Chart Macro
- Insert a code block macro inside the SVG Chart Macro
Edit the code block macro and choose SQL in the syntax highlighting field. (Currently only support SQL query statement starting with select )
- 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:
Jira
select p.pname as Project,it.pname as 'Issue Type',count(*) as Count from jiraissue ji join issuetype it on ji.issuetype=it.id join project p on p.id=ji.project group by p.pname,it.pname;