Hi All,
I am new to the confluence and working small requirement. I want to read CSV/txt file from local computer and do some manipulation on that read value before displaying confluence page. Is there any way we can do this using User macro or with predefined function?
Your answers will help me lot to meet my deadline.
Thanks lot,
Mohamed Asan
Hello Mohamed,
There's a new Table from CSV macro you could try in the Table Filter and Charts app. This macro allows you to output a table from CSV or TSV data source on the Confluence page.
By the way, Table from CSV supports outputting data not only from an attached file but also from a URL. And you can use the following data formats: Wiki markup, Markdown, Plain text.
Here's an example of how to use it and manipulate data with the Table Transformer macro then:
1. Add Table from CSV on the Confluence page.
Type in the name of the CSV file from Confluence attachments and click insert.
The table loaded:
2. Wrap the manually created table and Table from CSV with the Table Transformer macro.
Choose the preset needed or write your own SQL query.
Using both Table from CSV and Table Transformer you can load a file and manipulate its data.
Katerina
StiltSoft
hi
is there a way to configure the csv name dynamically, if for example i use Confiforms ?
i attach file to form entry and would like that a user will be able to use different file not pre defined in the macro
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Probably you can use ConfiForms ListView to show the data from your form and put the advised macro inside the macro body, in this macro body you can access ConfiForms field values via [entry.field_name] notations that can be passed (and evaluated to values first) to "inner macros"
Alex
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Ofer Rozenman
I am not sure that understood your use case. Could you clarify it, provide more details?
Would you like to have the whole list of attachments available in the Attachment with CSV box right away?
Katerina
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Why don't you just upload the file to Confluence after you're finished with it?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Anup,
The motivation is to automate the process. The file will be created by back end system in CSV format. And need to read to the file and put some extra content and formatting to display into the confluence page.
Thanks,
Mohamed Asan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
If you can use a Google sheet for your purpose then you could use a Sheets macro (free add-on available to download) to display it. Any modifications to the sheet would reflect on the Confluence page as it sort of acts like an iframe.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.