I'm dealing with a trivial shell script that invokes the
mysql binary on a remote server, and having org-babel capture its results as a table.
With sensitive information scrubbed, the source block resembles
#+BEGIN_SRC sh :results value table #!/bin/sh ssh remote.host 'mysql db -e "SELECT foo,bar,baz FROM stuff"' #+END_SRC
and its result is formatted as tab-separated values, the first row of which is a header naming the columns:
foo^Ibar^Ibaz value^Ivalue^Ivalue value^Ivalue^Ivalue ⋮
Org-babel correctly interprets this result as a table. What it doesn't do, and I haven't been able to figure out how to get it to do, is treat the first row of this result as a header. More specifically, I want there to be an hline automatically inserted after the first row, so that I can pass just the values to downstream code blocks, without having to have the code in them explicitly filter out the first line.
I'm (almost) sure there is a fairly trivial way to do this, because I've seen examples in other questions on Emacs SE of code block result tables which (appear to be) automatically formatted the way I want mine to be. I just haven't been able to find how to do it for myself in the org-babel documentation.