From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Eric Schulte" Subject: Re: Re: [BUG] org-babel-tangle causes Date: Sun, 27 Feb 2011 21:03:11 -0700 Message-ID: <87vd04yfeo.fsf@gmail.com> References: <87zkpha2de.fsf@gmail.com> <8039n9nswf.fsf@somewhere.org> <87zkph89b3.fsf@gmail.com> <878vx1yps1.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from [140.186.70.92] (port=48254 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PtuKS-00067R-AD for emacs-orgmode@gnu.org; Sun, 27 Feb 2011 23:03:29 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PtuKN-00031g-Da for emacs-orgmode@gnu.org; Sun, 27 Feb 2011 23:03:24 -0500 Received: from mail-gy0-f169.google.com ([209.85.160.169]:58287) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PtuKN-00031b-AI for emacs-orgmode@gnu.org; Sun, 27 Feb 2011 23:03:19 -0500 Received: by gyb13 with SMTP id 13so1770767gyb.0 for ; Sun, 27 Feb 2011 20:03:18 -0800 (PST) In-Reply-To: (Vladimir Alexiev's message of "Mon, 28 Feb 2011 00:58:02 +0000 (UTC)") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Vladimir Alexiev Cc: emacs-orgmode@gnu.org Vladimir Alexiev 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