From mboxrd@z Thu Jan 1 00:00:00 1970 From: Josh Mattoon Subject: Re: dates in a spreadsheet Date: Wed, 17 Mar 2010 13:45:51 -0700 Message-ID: <3a257d511003171345l631fcf37ic425a9d4904f402a@mail.gmail.com> References: <3a257d511003162304o7eea96b4u40c581bb3bd69521@mail.gmail.com> <87eijjynnm.fsf@stats.ox.ac.uk> <3a257d511003170951q342b2165vdcc51391c4277911@mail.gmail.com> <11255.1268855898@alphaville.usa.hp.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1474727439==" Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Ns0Au-0001NC-CO for emacs-orgmode@gnu.org; Wed, 17 Mar 2010 16:49:08 -0400 Received: from [140.186.70.92] (port=37736 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Ns0Ar-0000wY-NK for emacs-orgmode@gnu.org; Wed, 17 Mar 2010 16:49:07 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1Ns07j-0000Zb-Sa for emacs-orgmode@gnu.org; Wed, 17 Mar 2010 16:45:53 -0400 Received: from mail-gw0-f41.google.com ([74.125.83.41]:55161) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ns07j-0000ZU-Nn for emacs-orgmode@gnu.org; Wed, 17 Mar 2010 16:45:51 -0400 Received: by gwb17 with SMTP id 17so1185655gwb.0 for ; Wed, 17 Mar 2010 13:45:51 -0700 (PDT) In-Reply-To: <11255.1268855898@alphaville.usa.hp.com> 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: nicholas.dokos@hp.com Cc: Dan Davison , emacs-orgmode@gnu.org --===============1474727439== Content-Type: multipart/alternative; boundary=0016e6475b0220868404820533e7 --0016e6475b0220868404820533e7 Content-Type: text/plain; charset=ISO-8859-1 Hey Nick, the first one came through just fine. This is pretty cool but still not quite what I'm looking for. It totally helped me get what I wanted though! I wanted to have a separate row for each day so I could fill in activities. Modifying your example I get: | date | place | activity | notes | |------------------+---------+---------------------------+------------------| | <2010-03-19 Fri> | | | dummy | | <2010-03-20 Sat> | | | | | <2010-03-21 Sun> | moon | collect rocks | | | <2010-03-22 Mon> | jupiter | thrash around the red dot | | | <2010-03-23 Tue> | mars | see the little green men | | | <2010-03-24 Wed> | earth | | home, sweet home | #+TBLFM: @2$1 = <03-19-2010>::$1 = @-1$1 + 1 Exactly what I wanted! I can insert days, move them around, and just hit C-u C-c C-c to have it update. I'd like to understand how it works though, if you don't mind. What does the ::$1 synax mean? And how did it know that we were dealing with a date? On Wed, Mar 17, 2010 at 12:58 PM, Nick Dokos wrote: > Josh Mattoon wrote: > > > If I wanted to add an extra day on mars I could just enter a new row, > recalculate the forumula, and > > the dates would be automagically updated. It's not such a big deal in a > small example like this but > > I'm planning out a 3 week vacation with a fair number of destinations. > I'd like the day of week to > > display because some sites are closed on certain days. > > [Not sure what mailer mangled my previous reply to the point of > unrecognizability, but here is another attempt - I hope it's > cleaner. Let me know if there is a problem.] > > > | date | duration | place | activity | notes > | > > |------------------+----------+---------+---------------------------+------------------| > | <2010-03-17 Wed> | 0 | | | dummy > | > | <2010-03-17 Wed> | 3 | moon | collect rocks | > | > | <2010-03-20 Sat> | 5 | mars | see the little green men | > | > | <2010-03-25 Thu> | 5 | jupiter | thrash around the red dot | > | > | <2010-03-30 Tue> | | earth | | home, > sweet home | > #+TBLFM: @2$1 = <03-17-2010>::$1 = @-1$1 + @-1$2 > --0016e6475b0220868404820533e7 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hey Nick, the first one came through just fine. This is pretty cool but sti= ll not quite what I'm looking for. =A0It totally helped me get what I w= anted though! =A0I wanted to have a separate row for each day so I could fi= ll in activities. =A0Modifying your example I get:=A0

| date =A0 =A0 =A0 =A0 =A0 =A0 | place =A0 | activ= ity =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0| notes =A0 =A0 =A0 =A0 =A0 =A0|
|------------------+---------+---------------------------+----------= --------|
| <2010-03-19 Fri> | =A0 =A0 =A0 =A0 | =A0 =A0 = =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 | dummy =A0 =A0 =A0 =A0 =A0 =A0= |
| <2010-03-20 Sat> | =A0 =A0 =A0 =A0 | =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 =A0 =A0 =A0 =A0 | =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0|
| <2010-03-21 Sun> | moon =A0 =A0| collect rocks =A0 =A0 =A0 =A0 = =A0 =A0 | =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0|
| <2010-03-22 M= on> | jupiter | thrash around the red dot | =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0|
| <2010-03-23 Tue> | mars =A0 =A0| see the little green men =A0|= =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0|
| <2010-03-24 Wed> | = earth =A0 | =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 | home, swe= et home |
#+TBLFM: @2$1 =3D <03-19-2010>::$1 =3D @-1$1 + 1<= /div>

Exactly what I wanted! =A0I can insert days, move= them around, and just hit C-u C-c C-c to have it update. =A0I'd like t= o understand how it works though, if you don't mind. =A0What does the := :$1 synax mean? =A0And how did it know that we were dealing with a date?

On Wed, Mar 17, 2010 at 12:58 PM,= Nick Dokos <= nicholas.dokos@hp.com> wrote:
Josh Mattoon <joshmattoon@gmail.com> wrote:

> If I wanted to add an extra day on mars I could just enter a new row, = recalculate the forumula, and
> the dates would be automagically updated. It's not such a big deal= in a small example like this but
> I'm planning out a 3 week vacation with a fair number of destinati= ons. I'd like the day of week to
> display because some sites are closed on certain days.

[Not sure what mailer mangled my previous reply to the point of
unrecognizability, but here is another attempt - I hope it's
cleaner. Let me know if there is a problem.]


| date =A0 =A0 =A0 =A0 =A0 =A0 | duration | place =A0 | activity =A0 =A0 = =A0 =A0 =A0 =A0 =A0 =A0 =A0| notes =A0 =A0 =A0 =A0 =A0 =A0|
|------------------+----------+---------+---------------------------+------= ------------|
| <2010-03-17 Wed> | =A0 =A0 =A0 =A00 | =A0 =A0 =A0 =A0 | =A0 =A0 =A0= =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 | dummy =A0 =A0 =A0 =A0 =A0 =A0| | <2010-03-17 Wed> | =A0 =A0 =A0 =A03 | moon =A0 =A0| collect rocks = =A0 =A0 =A0 =A0 =A0 =A0 | =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0|
| <2010-03-20 Sat> | =A0 =A0 =A0 =A05 | mars =A0 =A0| see the little = green men =A0| =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0|
| <2010-03-25 Thu> | =A0 =A0 =A0 =A05 | jupiter | thrash around the r= ed dot | =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0|
| <2010-03-30 Tue> | =A0 =A0 =A0 =A0 =A0| earth =A0 | =A0 =A0 =A0 =A0= =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 | home, sweet home |
#+TBLFM: @2$1 =3D <03-17-2010>::$1 =3D @-1$1 + @-1$2

--0016e6475b0220868404820533e7-- --===============1474727439== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode --===============1474727439==--