diff options
author | Eric Schulte <schulte.eric@gmail.com> | 2014-01-08 09:56:21 -0700 |
---|---|---|
committer | Eric Schulte <schulte.eric@gmail.com> | 2014-01-08 09:57:40 -0700 |
commit | 8285763b973fe038c1970040cfc77473372f8d9f (patch) | |
tree | 388421fad7aff4a21de9cab29b71a365ee564fc3 | |
parent | d310a8760513d755a69c51d9576504cdf8a8f646 (diff) | |
download | org-mode-8285763b973fe038c1970040cfc77473372f8d9f.tar.gz |
update psql command to respect :colnames
Suggested by Joost Helberg on the Mailing list.
TINYCHANGE
* lisp/ob-sql.el (org-babel-execute:sql): Update psql command to
respect :colnames.
-rw-r--r-- | lisp/ob-sql.el | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/ob-sql.el b/lisp/ob-sql.el index bee457b..7b85df8 100644 --- a/lisp/ob-sql.el +++ b/lisp/ob-sql.el @@ -123,7 +123,8 @@ This function is called by `org-babel-execute-src-block'." (org-babel-process-file-name in-file) (org-babel-process-file-name out-file))) ('postgresql (format - "psql --set=\"ON_ERROR_STOP=1\" -A -P footer=off -F \"\t\" -f %s -o %s %s" + "psql --set=\"ON_ERROR_STOP=1\" %s -A -P footer=off -F \"\t\" -f %s -o %s %s" + (if colnames-p "" "-t") (org-babel-process-file-name in-file) (org-babel-process-file-name out-file) (or cmdline ""))) |