From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Dominik Subject: Re: filling cells automatically Date: Mon, 2 Jul 2007 12:45:18 +0200 Message-ID: <1541b72dae819418616412d830bded6c@science.uva.nl> References: <87hcp2636n.fsf@freemail.hu> Mime-Version: 1.0 (Apple Message framework v624) Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1I5JPC-0001JK-Pc for emacs-orgmode@gnu.org; Mon, 02 Jul 2007 06:45:18 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1I5JPC-0001J6-3A for emacs-orgmode@gnu.org; Mon, 02 Jul 2007 06:45:18 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1I5JPB-0001J3-RF for emacs-orgmode@gnu.org; Mon, 02 Jul 2007 06:45:17 -0400 Received: from korteweg.uva.nl ([146.50.98.70]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1I5JPB-0002nM-BR for emacs-orgmode@gnu.org; Mon, 02 Jul 2007 06:45:17 -0400 In-Reply-To: <87hcp2636n.fsf@freemail.hu> 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: ignotus@freemail.hu Cc: emacs-orgmode@gnu.org On Jun 20, 2007, at 17:44, ignotus@freemail.hu wrote: > Dear Org users! > > I would like to have the following functionality: I have a table like > this: > > | number1 | number2 | description | > |---------+---------+-------------| > | 1 | 1 | a | > | 1 | 2 | b | > | 1 | 3 | c | > | 1 | 4 | d | > |---------+---------+-------------| > | 2 | 1 | aa | > | 2 | 2 | bb | > | 2 | 3 | cc | > | 2 | 4 | dd | > |---------+---------+-------------| > | 3 | 1 | aaa | > | 3 | 2 | bbb | > | 3 | 3 | ccc | > | 3 | 4 | ddd | > |---------+---------+-------------| > > I would like to generate number1 and number2 rows automatically (so > when > I insert something the numbering will be okay), is this possible? Well > I know it is, but is it possible within the current org table > framework? This is currently difficult because of a bug in org-mode in the treatment of fields that have a field formula assigned, but also are in a column with a column formula. This bug will be fixed in the next version, and then you can do: | number1 | number2 | description | |---------+---------+-------------| | 1 | 1 | a | | 1 | 2 | b | | 1 | 3 | c | | 1 | 4 | d | |---------+---------+-------------| | 2 | 1 | aa | | 2 | 2 | bb | | 2 | 3 | cc | | 2 | 4 | dd | |---------+---------+-------------| | 3 | 1 | aaa | | 3 | 2 | bbb | | 3 | 3 | ccc | | 3 | 4 | ddd | |---------+---------+-------------| #+TBLFM: $1=@-1::$2=1+@-1::@2$1=1::@2$2=1::@6$1=2::@6$2=1::@10$1=3::@10$2=1 Make sure that you insert new rows with Org-mode commands, not by hand. With this setup, C-u C-c C-c will update the table and fill rows 1 and 2. Hope this helps - Carsten