I use Michael Brand's solution proposed here and cataloged by Derek Feichtinger here (make sure to view the file in raw mode, otherwise the source is hidden by GitHub).
For convenience, I reproduce the code below:
* Exporting tables with some columns hidden
It is desirable to be able and hide columns in exported output. This is often the
case in tables where a lot of computations are done, and where intermediate
results end up in columns that one does not want to end up in the exported document.
This functionality is currently not available by standard org, but since this is Emacs, a simple function
implementing this functionality was published by [[https://github.com/brandm][Michael Brand]] within this [[http://lists.gnu.org/archive/html/emacs-orgmode/2016-05/msg00027.html][emacs-orgmode thread]].
#+BEGIN_SRC emacs-lisp :results silent :exports source
(defun dfeich/org-export-delete-commented-cols (back-end)
"Delete columns $2 to $> marked as `<#>' on a row with `/' in $1.
If you want a non-empty column $1 to be deleted make it $2 by
inserting an empty column before and adding `/' in $1."
(while (re-search-forward "^[ \t]*| +/ +|\\(.*|\\)? +\\(<#>\\) *|" nil t)
(goto-char (match-beginning 2))
(org-table-delete-column)
(beginning-of-line)))
(add-hook 'org-export-before-processing-hook #'dfeich/org-export-delete-commented-cols)
;; (remove-hook 'org-export-before-processing-hook #'dfeich/org-export-delete-commented-cols)
#+END_SRC
The exported table will have col2 removed.
| | col1 | col2 | col3 |
| / | <r> | <#> | |
| | a1 | a2 | a3 |
| | b1 | b2 | b3 |