* Bug: table/calc: subscr() fails with *bold* headline
@ 2016-09-03 11:30 Karl Voit
2016-09-04 14:33 ` Nicolas Goaziou
0 siblings, 1 reply; 2+ messages in thread
From: Karl Voit @ 2016-09-03 11:30 UTC (permalink / raw)
To: emacs-orgmode
Hi!
I've found a bug when using subscr() to copy a value from a previous
row. If the corresponding headline is in *bold* letters, the formula
does not work:
| *Value* | Previous Value |
|---------+----------------|
| 1 | |
| 2 | #ERROR |
| 3 | #ERROR |
| 4 | #ERROR |
#+TBLFM: @3$2..@>$2 = subscr(@<$1..@>$1, @# - 1)
With ";E" added:
| *Value* | Previous Value |
|---------+----------------|
| 1 | |
| 2 | #ERROR |
| 3 | #ERROR |
| 4 | #ERROR |
#+TBLFM: @3$2..@>$2 = subscr(@<$1..@>$1, @# - 1); E
Working version without *bold* in $1:
| Value | *Previous Value* |
|-------+------------------|
| 1 | |
| 2 | 1 |
| 3 | 2 |
| 4 | 3 |
#+TBLFM: @3$2..@>$2 = subscr(@<$1..@>$1, @# - 1)
Working version without *bold* at all:
| Value | Previous Value |
|-------+----------------|
| 1 | |
| 2 | 1 |
| 3 | 2 |
| 4 | 3 |
#+TBLFM: @3$2..@>$2 = subscr(@<$1..@>$1, @# - 1)
At my side: Org-mode version 8.3.4 (release_8.3.4-33-gd522fc)
--
mail|git|SVN|photos|postings|SMS|phonecalls|RSS|CSV|XML to Org-mode:
> get Memacs from https://github.com/novoid/Memacs <
https://github.com/novoid/extract_pdf_annotations_to_orgmode + more on github
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Bug: table/calc: subscr() fails with *bold* headline
2016-09-03 11:30 Bug: table/calc: subscr() fails with *bold* headline Karl Voit
@ 2016-09-04 14:33 ` Nicolas Goaziou
0 siblings, 0 replies; 2+ messages in thread
From: Nicolas Goaziou @ 2016-09-04 14:33 UTC (permalink / raw)
To: Karl Voit; +Cc: Karl Voit, emacs-orgmode
Hello,
Karl Voit <devnull@Karl-Voit.at> writes:
> I've found a bug when using subscr() to copy a value from a previous
> row. If the corresponding headline is in *bold* letters, the formula
> does not work:
>
> | *Value* | Previous Value |
> |---------+----------------|
> | 1 | |
> | 2 | #ERROR |
> | 3 | #ERROR |
> | 4 | #ERROR |
> #+TBLFM: @3$2..@>$2 = subscr(@<$1..@>$1, @# - 1)
This is not a bug in Org.
Calc probably considers *Value* as an invalid operation (missing
operands). You can simply ignore the header line
subscr(@<<$1..@>$1, @# - 1)
or turn any suspicious value as a number
subscr(@<$1..@>$1, @# - 1);N
Regards,
--
Nicolas Goaziou
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-09-04 14:33 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-09-03 11:30 Bug: table/calc: subscr() fails with *bold* headline Karl Voit
2016-09-04 14:33 ` Nicolas Goaziou
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).