[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Orgmode] date functions in org tables
From: |
Nick Dokos |
Subject: |
Re: [Orgmode] date functions in org tables |
Date: |
Fri, 25 Feb 2011 17:02:52 -0500 |
Thorsten <address@hidden> wrote:
>
> Hello,
> is there something like a column formula in org that enables me to introduce a
> date in the first row and then automatically fills the other rows of
> that column with followup dates (+ 1 day or + 1 week i.e.)
> like this:
>
> | date | kg |
> |-----------------+----|
> | <2011-02-08 Di> | 86 |
> | <2011-02-09 Mi> | 85 |
> | etc. | |
>
> thanks for any hints
Interactively S-<RET> will insert a row with the next date (i.e. the + 1
day bit), but I don't know of a way to make it skip by larger
steps (i.e. the + 7 days bit).
With a table formula, you can skip by as much as you want:
--8<---------------cut here---------------start------------->8---
* Consecutive dates
| Date | Weight |
|------------------+--------|
| <2011-02-25 Fri> | 71 |
| <2011-03-04 Fri> | |
| <2011-03-11 Fri> | |
| <2011-03-18 Fri> | |
| <2011-03-25 Fri> | |
#+TBLFM: @2$1=<2011-02-25 Fri>::$1=<@-1$1>+7
--8<---------------cut here---------------end--------------->8---
using a field formula to set the first entry and a column formula
to calculate the rest, but it just fills up pre-existing rows. IOW,
if you want a bigger table, you have to insert a number of empty
rows and then recalculate.
HTH,
Nick