How do I list and count all pages with attachments in Confluence?
プラットフォームについて: Server および Data Center のみ。この記事は、Server および Data Center プラットフォームのアトラシアン製品にのみ適用されます。
サーバー*製品のサポートは 2024 年 2 月 15 日に終了しました。サーバー製品を利用している場合は、アトラシアンのサーバー製品のサポート終了のお知らせページにて移行オプションをご確認ください。
*Fisheye および Crucible は除く
目的
To get a list of all pages in Confluence with the number or attachments.
ソリューション
Run the below query into your Confluence Database:
PosgreSQL
select count(c.TITLE) as "Number of attachments",
s.spacename,
c2.TITLE as Page_Title,
'http://<confluence_base_url>/pages/viewpageattachments.action?pageId='||c.PAGEID as Location
from CONTENT c
join CONTENT c2 ON c.PAGEID = c2.CONTENTID
join SPACES s on c2.SPACEID = s.SPACEID
where c.CONTENTTYPE = 'ATTACHMENT'
and c.prevver is null
and c.content_status='current'
group by Page_Title, s.spacename, c.PAGEID
order by 1 desc;
Replace <confluence_base_url> with your Confluence Base URL. This was tested against PostgreSQL.
最終更新日 2024 年 11 月 27 日
Powered by Confluence and Scroll Viewport.