emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Myles English <mylesenglish@gmail.com>
To: Johann Spies <johann.spies@gmail.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: sh - script: how to control the output.
Date: Mon, 02 Nov 2015 11:02:45 +0000	[thread overview]
Message-ID: <877fm0d5pm.fsf@gmail.com> (raw)
In-Reply-To: <CAGZ55DTS0FBs77SE2RPBe2aTCc7r=6QqQKXUb1V9hqmCs+dn=w@mail.gmail.com>

Hello Johann,

Johann Spies writes:

> In the normal shell, I can do:
>
>  echo '\d wos.wos_papers_by_subject_mv' | psql -h localhost -p 63334
> book_citation | grep '[+|]'
>
> and get the output:
>
>   Column  |  Type   | Modifiers
> ----------+---------+-----------
>  id       | integer |
>  subject  | citext  |
>  articles | bigint  |
>
> When I try this in org-mode:
>
>
> #+BEGIN_SRC sh
>
> echo '\d wos.wos_papers_by_subject_mv' | psql -h localhost -p 63334
> book_citation | grep '[+|]'
>
>
> #+END_SRC
>
> #+results:
> | Column                           |   |   | Type    |   |   | Modifiers |
> | ----------+---------+----------- |   |   |         |   |   |           |
> | id                               |   |   | integer |   |   |           |
> | subject                          |   |   | citext  |   |   |           |
> | articles                         |   |   | bigint  |   |   |           |
>
> What should I do to get the following in org-mode as a result:

You could try out some of the options for the ":results" header
argument, as described here:

http://orgmode.org/manual/results.html#results

Myles

  reply	other threads:[~2015-11-02 11:02 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-02  7:35 sh - script: how to control the output Johann Spies
2015-11-02 11:02 ` Myles English [this message]
2015-11-02 13:00   ` Johann Spies

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=877fm0d5pm.fsf@gmail.com \
    --to=mylesenglish@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=johann.spies@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).