How to report on links in a Confluence instance

お困りですか?

アトラシアン コミュニティをご利用ください。

コミュニティに質問

プラットフォームについて: Data Center - この記事は、Data Center プラットフォームのアトラシアン製品に適用されます。

このナレッジベース記事は製品の Data Center バージョン用に作成されています。Data Center 固有ではない機能の Data Center ナレッジベースは、製品のサーバー バージョンでも動作する可能性はありますが、テストは行われていません。サーバー*製品のサポートは 2024 年 2 月 15 日に終了しました。サーバー製品を利用している場合は、アトラシアンのサーバー製品のサポート終了のお知らせページにて移行オプションをご確認ください。

*Fisheye および Crucible は除く

目的

For auditing purposes, you may wish to see what links are being used on each page within a Confluence instance. 

Generating the report with SQL

  • Links are stored in the LINKS table of the database
  • Each link is attributed by a specific content ID
  • Each piece of content is linked to a space ID.

The following is a good starting point for generating such a report. You may need to adjust this query so it returns some more detailed information, or excludes certain types of links or spaces.

SELECT s.spacename as Space, c.title as Page, l.destspacekey as SpaceOrProtocol, l.destpagetitle as Destination
FROM LINKS l
JOIN CONTENT c ON c.contentid = l.contentid
JOIN SPACES s ON s.spaceid = c.spaceid
WHERE c.prevver IS NULL
ORDER BY l.destspacekey

How to understand this output:

Understanding the output:

This will grab the:

  • Space of the page a link appears on
  • The title of the page a link appears on
  • The destination space key (or protocol, if it's an external link; such as mailto or https)
  • The destination page title (or URL if it's an external link - note that the URL will not contain the protocol, as that's recorded in the space key column).
  • So you might see output like this:
スペースページSpaceOrProtocoldestination
DSWelcome to ConfluencedsPrettify the page with an image (step 4 of 9)
テストTest Pagehttp//www.google.com/

This would tell us we've got two links:

  1. On the "Welcome to Confluence" page in the "DS" space, there's a link to the page "Prettify the page with an image (step 4 of 9)", which resides in the "DS" space
  2. On the "Test Page" in the "TEST" space, there's a link to "http://www.google.com/"

最終更新日: 2024 年 12 月 4 日

この内容はお役に立ちましたか?

はい
いいえ
この記事についてのフィードバックを送信する
Powered by Confluence and Scroll Viewport.