Atlassian uses cookies to improve your browsing experience, perform analytics and research, and conduct advertising. Accept all cookies to indicate that you agree to our use of cookies on your device. Atlassian cookies and tracking notice, (opens new window)
Teams
, (opens new window)

SQL for Confluence
Results will update as you type.
  • SQL for Confluence
  • _InclusionsLibrary
  • _Archive
    • User's Guide
    • Administrator's Guide
      • Get Started - Configuration
      • Getting Help And Support
      • Configure Data Sources
        • Configure Application Server-based Data Sources
        • Data Source Picker
        • SQL for Confluence datasource configuration
      • Configure Data Source Profiles
      • Pro Tips
      • Better Together
      • Editions
      • Analytics Data
    • SQL Macro
    • SQL-file Macro
    • SQL-query Macro
    You‘re viewing this with anonymous access, so some content might be blocked.
    /
    Configure Data Sources

    Configure Data Sources

    Jun 08, 2018

    Overview

    (info) At least one Data Source or Data Source Profile needs to be configured before you can use the SQL Macro or SQL-query Macro or SQL-file.

    This page describes two methods to configure Data Sources for the macros provided by SQL for Confluence. SQL Macros use Data Sources to access databases. A Data Source defines the access parameters including credentials. The same database access information is required for each method. Similarly, the database must allow access using the information provided no matter which method is used.

    MethodPrimary BenefitKey AttributesDocumentationExpress EditionPro Edition
    Data Source ProfilesConvenience
    • SQL for Confluence specific configuration
    • Convenience 
      • Configuration change in affect immediately
      • File system access not needed
    • Can reference application server defined Data Sources
    • Recommended for evaluation, testing, short term scenarios
    • Medium or heavier use scenarios should also employ Cache for Confluence
    Configure Data Source Profiles(tick)(tick)
    Application Server-based Data SourcePerformance
    • Application server based configuration
    • Best performance via connection pooling/reuse
    • Requires Confluence restart after configuration change
    • Recommended for long term/heavy use scenarios
    Configure application server-based data sources - 9.x(error)(tick)

    You can configure data sources using either of the methods or both - for instance use a data source profile while testing or for low-use scenarios, then switch to a server-based data source when/if it becomes clear it is going to be around for a long while.

    Macro Security for data source access control

    Macro Security for Confluence can be used to control access to specific Data Sources in the same way no matter what method is used.

    Use Cache and Future macros around SQL macros

    Give your users better response times and reduce the load on your server by using Cache for Confluence macros for heavy use scenarios.

    The Data Source is referenced using the dataSource (Data Source name) parameter. The exact configuration of a Data Source is application server and database specific. The configuration must be done by a Confluence administrator and the Confluence application server must be restarted for changes to be active. The configuration must be done very carefully as any errors result in the Data Source being unusable (sad). Each database you need to access in Confluence needs to a have a Data Source configuration.

    , multiple selections available,

    Need support? Create a request with our support team.

    Copyright © 2005 - 2025 Appfire | All rights reserved.

    {"serverDuration": 13, "requestCorrelationId": "50f8f510304a43cdb1e1cd059c352036"}