all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Cecil Westerhof <CecilWesterhof@xs4all.nl>
To: org-mode <emacs-orgmode@gnu.org>
Subject: Re: Making a list to string
Date: Thu, 12 Jul 2007 07:23:37 +0200	[thread overview]
Message-ID: <1184217817.6283.165.camel@Barebusta.DecebalComp> (raw)
In-Reply-To: <b71b18520707111459r27a360b2w814fe9d1f93ea362@mail.gmail.com>

Op wo, 11-07-2007 te 16:59 -0500, schreef Eddward DeVilla:
> I take that back.  I think it is right.  I thought hard coded and
> frodatum were supposed to match.  Unfortunately, it looks like the
> mailed mangles the formula line.
> 
> On 7/11/07, Eddward DeVilla <eddward@gmail.com> wrote:
> > Is this any better.  I don't think it's entirely right yet.
> >
> >    |---+------------+------------+------------+------------|
> >    |   |      datum | from datum | hard coded |            |
> >    |---+------------+------------+------------+------------|
> >    | # | 2007-01-01 |          1 |          1 | 2007-01-01 |
> >    | # | 2007-07-09 |        190 |        190 | 2007-07-09 |
> >    | # | 2007-07-11 |        192 |        192 | 2007-07-11 |
> >    | # | 2007-09-11 |        254 |          1 | 2007-09-11 |
> >    | # |   20071012 |        192 |          1 |   20071012 |
> >    |---+------------+------------+------------+------------|
> > #+TBLFM: $3='(time-to-day-in-year (org-read-date t t (concat
> > $2)))::$5='(concat $2)::@2$4='(time-to-day-in-year (org-read-date t t
> > "2007-01-01"));N::@3$4='(time-to-day-in-year (org-read-date t t
> > "2007-07-09"));N::@4$4='(time-to-day-in-year (org-read-date t t
> > "2007-07-11"));N::@5$4='(time-to-day-in-year (org-read-date t t
> > "2007-01-01"));N

Yes, it looks like it works completly. (What I am missing is a knowledge
of Lisp. Thus that will come.)

One thing bugs me. I am used to end a formula ending with ';N'.
Sometimes if you do not do this, this geves an error. But in this case
this gives an error:
        Substitution history of formula
        Orig:   '(time-to-day-in-year (org-read-date t t (concat $2)))
        $xyz->  '(time-to-day-in-year (org-read-date t t (concat $2)))
        @r$c->  '(time-to-day-in-year (org-read-date t t (concat $2)))
        $1->    '(time-to-day-in-year (org-read-date t t (concat 2007)))
        Result: #ERROR
        Format: NONE
        Final:  #ERROR
When using nothing after the formula, I get:
        Substitution history of formula
        Orig:   '(time-to-day-in-year (org-read-date t t (concat $2)))
        $xyz->  '(time-to-day-in-year (org-read-date t t (concat $2)))
        @r$c->  '(time-to-day-in-year (org-read-date t t (concat $2)))
        $1->    '(time-to-day-in-year (org-read-date t t (concat #("2007-01-01" 0 1 (hilit-chg hilit-chg lazy-lock t) 1 2 (hilit-chg hilit-chg lazy-lock t) 2 3 (hilit-chg hilit-chg lazy-lock t) 3 4 (hilit-chg hilit-chg lazy-lock t) 4 5 (hilit-chg hilit-chg lazy-lock t) 5 6 (hilit-chg hilit-chg lazy-lock t) 6 8 (hilit-chg hilit-chg lazy-lock t) 8 9 (hilit-chg hilit-chg lazy-lock t) 9 10 (hilit-chg hilit-chg lazy-lock t)))))
        Result: 1
        Format: NONE
        Final:  1
And when I put ';S' after the formula, I get the same as with nothing
after the formula.
Why this error by ';N'?
Also what is the meaning of the strange expansion by concat? Maybe not
neccesary, but I like to understand what is happening.

-- 
Cecil Westerhof <CecilWesterhof@xs4all.nl>

  reply	other threads:[~2007-07-12  5:23 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-07-11 20:43 Making a list to string Cecil Westerhof
2007-07-11 21:54 ` Eddward DeVilla
2007-07-11 21:59   ` Eddward DeVilla
2007-07-12  5:23     ` Cecil Westerhof [this message]
2007-07-12  6:04       ` Eddward DeVilla
2007-07-12  6:10         ` Cecil Westerhof
2007-07-13 13:47       ` Carsten Dominik

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1184217817.6283.165.camel@Barebusta.DecebalComp \
    --to=cecilwesterhof@xs4all.nl \
    --cc=emacs-orgmode@gnu.org \
    /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 external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.