How can I export a comma separated list of values ​​from org-mode table column

I have a table in org-mode with emails in one column. I want to collect all emails as a comma separated list, but I don't know how. It looks like something pretty simple, but I can't seem to find a solution anywhere on the internet.

What's the easiest way to do this?

+3


source to share


3 answers


By dipping my fingers into org mode, a very simple formula @1..

will do the trick of creating a list from the values ​​in the current column from rows 1 and onwards, since it is just concatenated to the default comma values. eg:.

#+TBLFM: @5$2=@1..

      



(followed by C-c C-cfor evaluation), will list in row 5, column 2, all values ​​in column 2.

It ends the bracketed list, but that's clearly not a problem for the manual approach.

+3


source


One manual approach is to use the rectangle edit commands to extract the contents of that column (which should be well aligned with org mode) and then just search and replace to convert to CSV format:

  • C-SPC in the first corner
  • C-x r k in the opposite corner
  • C-/to undo kill (no default copy-rectangle command)

Then in the buffer where you want to get the list of addresses:



  • C-x r yto take out the rectangle
  • C-x C-x to exchange point and mark, marking area
  • C-M-% to find and replace regular expressions within a scope:

C-M-% SPC * C-q C-j RET , RET !

+2


source


Does Mx org-table-export do what you want?

0


source







All Articles