* Table calculations with hline references
@ 2015-01-19 0:19 Daniel Hornung
2015-01-19 5:07 ` Aaron Ecay
0 siblings, 1 reply; 3+ messages in thread
From: Daniel Hornung @ 2015-01-19 0:19 UTC (permalink / raw)
To: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 1068 bytes --]
Hi,
I am trying to calculate a field using references to horizontal lines
according to http://orgmode.org/manual/References.html
For example:
| col1 | col2 |
|------+------|
| foo | 1 |
| bar | 2 |
| baz | 4 |
|------+------|
| sum | |
| | |
#+TBLFM: @II+1$2=vsum(@I$2..@II$2)
The field to the right of "sum" (@5$2 as a fixed reference) should be "7".
The output is as follows though (the cursor was in the "baz" field
when I pressed "C-u C-c *" to recalculate all formulas):
| col1 | col2 |
|------+------|
| foo | 1 |
| bar | 2 |
| 7 | 7 |
|------+------|
| 10 | 10 |
| | |
#+TBLFM: @II+1$2=vsum(@I$2..@II$2)
Could anyone enlighten me where I made a mistake here?
Thanks a lot,
Daniel
--
Mein öffentlicher Schlüssel / My public key: 4096R/600ACB3B 2012-04-01
Fingerabdruck / Fingerprint:
9902 575B B9A0 C339 CFDF 250B 9267 CA6B 600A CB3B
Runterladen z.B. bei/ Get it e.g. from:
pgp.mit.edu, subkeys.pgp.net, pgp.uni-mainz.de, pool.sks-keyservers.net, ...
[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Table calculations with hline references
2015-01-19 0:19 Table calculations with hline references Daniel Hornung
@ 2015-01-19 5:07 ` Aaron Ecay
2015-01-19 21:18 ` Daniel Hornung
0 siblings, 1 reply; 3+ messages in thread
From: Aaron Ecay @ 2015-01-19 5:07 UTC (permalink / raw)
To: Daniel Hornung, emacs-orgmode
Hi Daniel,
What version of org are you using? Using a hline-relative reference on
the lhs of a formula is not allowed in the current development version
of org (i.e. the master branch). Presumably because it doesn’t work
correctly, as you have discovered.
The patch to prevent this was made over a year ago (2013-11-05). However,
as far as I can tell it has not been in any released version of org. I
tried to ascertain this using the command:
git tag --contains a2c71a6
Which returns only:
beta_8.3
release_8.3beta
Sorry that there’s not a more satisfying answer,
--
Aaron Ecay
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Table calculations with hline references
2015-01-19 5:07 ` Aaron Ecay
@ 2015-01-19 21:18 ` Daniel Hornung
0 siblings, 0 replies; 3+ messages in thread
From: Daniel Hornung @ 2015-01-19 21:18 UTC (permalink / raw)
To: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 1308 bytes --]
On Monday, 19. January 2015 00:07:39 Aaron Ecay wrote:
> Hi Daniel,
>
> What version of org are you using? Using a hline-relative reference on
> the lhs of a formula is not allowed in the current development version
> of org (i.e. the master branch). Presumably because it doesn’t work
> correctly, as you have discovered.
>
> The patch to prevent this was made over a year ago (2013-11-05). However,
> as far as I can tell it has not been in any released version of org. I
> tried to ascertain this using the command:
>
> git tag --contains a2c71a6
>
> Which returns only:
>
> beta_8.3
> release_8.3beta
Hi Aaron,
I tested it with the latest version from ELPA:
Org-mode version 8.2.10 (8.2.10-29-g89a0ac-elpa @
/home/daniel/.emacs.d/elpa/org-20150112/)
But thanks for the hint that this is a known problem, I will just stick with
fixed references which are fine, as long as I remember not to delete or insert
lines with generic delete or copy&paste commands.
Cheers,
Daniel
--
Mein öffentlicher Schlüssel / My public key: 4096R/600ACB3B 2012-04-01
Fingerabdruck / Fingerprint:
9902 575B B9A0 C339 CFDF 250B 9267 CA6B 600A CB3B
Runterladen z.B. bei/ Get it e.g. from:
pgp.mit.edu, subkeys.pgp.net, pgp.uni-mainz.de, pool.sks-keyservers.net, ...
[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-01-19 21:18 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-01-19 0:19 Table calculations with hline references Daniel Hornung
2015-01-19 5:07 ` Aaron Ecay
2015-01-19 21:18 ` Daniel Hornung
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).