Additional database access on the wiki page

Hello, community. I'm just wondering what the proper way for that would be... The goal is to display a selection form on a confluence page to filter and display entries of a separate custom database table. I want to create a new table in the confluence database like

Harry 30 meat

John 25 vegetables

Jennifer 27 meat

And then I want to create a selection form on the confluence page where I could filter the table for a 25 years old person who likes vegetables :-) And show the results.

I thought about creating a new table in the confluence database, then embed some javascript/php on the confluence web page in question to access the table. Is that the right way? I'm quite new to confluence...

BR

Ewgenij

3 answers

1 accepted

This widget could not be displayed.

Hi Ewgenji,

Another idea for that end would be to create a page to store that information and then use something like the Confluence SQL plugin from Bob swift (which is a third party plugin).

I would avoid creating tables in Confluence database, since that kind of customization could cause some problems during upgrade or data restoration procedures.

Also this page might help you if you decide to play around Confluence database.

Thanks and Regards,
David|Atlassian Support

Hello, thank you for your answer, what do you mean by "to create a page to store that information"?

BR

Ewgenij

This widget could not be displayed.

Ewgenij

I'd just like to amplify David's point. The Confluence SQL macro allow you to query and display data from an external database. Your would add a new datasource to your Confluence instnace in the following manner.

https://confluence.atlassian.com/display/DOC/Configuring+a+MySQL+Datasource+in+Apache+Tomcat

You wouldn't create a paget ostore that information, but an entirely new database. You could then use the SQL macro on a page of your chosing to display your desired information. To my knowledge you can't use a page in confluene as a datasource. I think David is trying to suggest decoupling the Confluence database and the new datasource to avoid problems during upgrade.

Hello Daniel, thank you. "Confluence SQL macro" you mean this plugin: https://marketplace.atlassian.com/plugins/org.swift.confluence.sql?Or something else?

This widget could not be displayed.

Do I understand it right, that I'm supposed to use the HTML Macro to embed javascript to a Confluence page? If so, I have to activate HTML Macros for all Confluence pages, and everybody with access to Confluence can put scripts on any page. Is that correct?

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Sep 17, 2018 in Confluence

Why start from scratch? Introducing four new templates for Confluence Cloud

Hi my Community friends!  For those who don't know me, I'm a product marketer on the Confluence Cloud team - nice to meet you! For those of you who do, you know that I've been all up in your Co...

602 views 8 6
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you