emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: "Eric Schulte" <schulte.eric@gmail.com>
To: Vladimir Alexiev <vladimir@sirma.bg>
Cc: emacs-orgmode@gnu.org
Subject: Re: Re: [BUG] org-babel-tangle causes
Date: Sun, 27 Feb 2011 21:03:11 -0700	[thread overview]
Message-ID: <87vd04yfeo.fsf@gmail.com> (raw)
In-Reply-To: <loom.20110228T013225-163@post.gmane.org> (Vladimir Alexiev's message of "Mon, 28 Feb 2011 00:58:02 +0000 (UTC)")

Vladimir Alexiev <vladimir@sirma.bg> writes:

> I found a simple WORKAROUND. 
> Kindly put this in the documentation of :colnames,
> at the end of the nil value:
>
> Please note that such "table disassembly" does not work with var
> indexing.  As a simple workaround, put the #+tblname AFTER the hline
> (not before the table).

Done, thanks for the suggestion

> 
> For example:
>
>   #+STARTUP:  showeverything
>   #+BABEL:    :tangle yes
>
>   | colA | colB |
>   |------+------|
>   #+tblname: table
>   | a1   | b1   |
>   | a2   | b2   |
>
>   #+begin_src perl :var a=table[*,0] :var b=table[*,1]
>   $a; $b;
>   #+end_src 
>
> If you tangle this source with C-c C-x t, you can see 
> that the assignments are correct.
>

I think that the following would be cleaner.  This is the workaround I
had in mind in my previous email, sorry I should have explicitly
mentioned this option.

#+tblname: perl-table-w-hline
| colA | colB |
|------+------|
| a1   | b1   |
| a2   | b2   |

#+headers: :var b=perl-table-w-hline[2..,1]
#+headers: :var a=perl-table-w-hline[2..,0]
#+begin_src perl :tangle yes
  $a; $b;
#+end_src 

Best -- Eric

      reply	other threads:[~2011-02-28  4:03 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-27 13:57 [BUG] org-babel-tangle causes "Wrong type argument: sequencep, hline" Vladimir Alexiev
2011-02-27 16:06 ` Eric Schulte
2011-02-27 20:07   ` Sébastien Vauban
2011-02-27 21:19     ` Eric Schulte
2011-02-27 22:41       ` Sébastien Vauban
2011-02-27 23:21       ` Vladimir Alexiev
2011-02-28  0:19         ` Eric Schulte
2011-02-28  0:58           ` [BUG] org-babel-tangle causes Vladimir Alexiev
2011-02-28  4:03             ` Eric Schulte [this message]

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=87vd04yfeo.fsf@gmail.com \
    --to=schulte.eric@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=vladimir@sirma.bg \
    /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).