all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Featur request org-table-iterate-table-subtree
@ 2015-10-25  1:18 Charles Millar
  2015-11-27 21:27 ` Charles Millar
  0 siblings, 1 reply; 4+ messages in thread
From: Charles Millar @ 2015-10-25  1:18 UTC (permalink / raw)
  To: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 672 bytes --]

Please see the attached example. If I call 
org-table-iterate-buffer-tables, Summary1 and Summary2 both are 
calculated using the referenced tables in heading "first set of tables" 
and the tables in the second heading are disregarded.

Without going into the details there are times when I use certain form 
tables in separate headlines in the same file. The entries are different 
in each and I believe that a function perhaps 
"org-table-iterate-subtree-tables" would be a useful addition to 
org-table.el.

Please note that narrowing the buffer to the second headline does not 
help since the code in org-table-iterate-buffer-tables widens the buffer.

Charlie Millar

[-- Attachment #2: OrgTableExample.org --]
[-- Type: text/plain, Size: 2185 bytes --]

* first set of tables

#+TBLNAME: SUMMARY1
| CHARGES        |      |       |
| Schedule "A"   | 6.00 |       |
| Schedule "A-1" | 6.00 |       |
| Schedule "A-2" | 6.00 |       |
| total          |      | 18.00 |
#+TBLFM: @>$>=vsum(@2$2..@4$2);%.2f::@2$2=remote(SCHEDA,@>$>);%.2f::@3$2=remote(SCHEDA1,@>$>);%.2f::@4$2=remote(SCHEDA2,@>$>);%.2f

#+TBLNAME: SCHEDA
| Description      | Basis |
|------------------+-------|
| Something A      |  1.00 |
| Something else A |  2.00 |
| Another thing A  |  3.00 |
| Total            |  6.00 |
#+TBLFM: @>$>=vsum(@I$>..@>>$>);%.2f

#+NAME: SCHEDA1
#+TBLNAME: SCHEDA
| Description        | Basis |
|--------------------+-------|
| Something A-1      |  1,00 |
| Something else A-1 |  2.00 |
| Another thing A-1  |  3.00 |
| Total              |  6.00 |
#+TBLFM: @>$>=vsum(@I$>..@>>$>);%.2f

#+NAME: SCHEDA2
#+TBLNAME: SCHEDA
| Description        | Basis |
|--------------------+-------|
| Something A-2      |  1.00 |
| Something else A-2 |  2.00 |
| Another thing A-2  |  3.00 |
| Total              |  6.00 |
#+TBLFM: @>$>=vsum(@I$>..@>>$>);%.2f


* second set of tables

#+TBLNAME: SUMMARY2
| CHARGES        |      |       |
| Schedule "A"   | 6.00 |       |
| Schedule "A-1" | 6.00 |       |
| Schedule "A-2" | 6.00 |       |
| total          |      | 18.00 |
#+TBLFM: @>$>=vsum(@2$2..@4$2);%.2f::@2$2=remote(SCHEDA,@>$>);%.2f::@3$2=remote(SCHEDA1,@>$>);%.2f::@4$2=remote(SCHEDA2,@>$>);%.2f

#+TBLNAME: SCHEDA
| Description      | Basis |
|------------------+-------|
| Something A      |  3.00 |
| Something else A |  2.00 |
| Another thing A  |  3.00 |
| Total            |  8.00 |
#+TBLFM: @>$>=vsum(@I$>..@>>$>);%.2f

#+NAME: SCHEDA1
#+TBLNAME: SCHEDA
| Description        | Basis |
|--------------------+-------|
| Something A-1      |  3.00 |
| Something else A-1 |  2.00 |
| Another thing A-1  |  3.00 |
| Total              |  8.00 |
#+TBLFM: @>$>=vsum(@I$>..@>>$>);%.2f

#+NAME: SCHEDA2
#+TBLNAME: SCHEDA
| Description        | Basis |
|--------------------+-------|
| Something A-2      |  3.00 |
| Something else A-2 |  2.00 |
| Another thing A-2  |  3.00 |
| Total              |  8.00 |
#+TBLFM: @>$>=vsum(@I$>..@>>$>);%.2f



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2015-12-07 22:59 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-25  1:18 Featur request org-table-iterate-table-subtree Charles Millar
2015-11-27 21:27 ` Charles Millar
2015-12-03 19:17   ` Aaron Ecay
2015-12-07 22:58     ` Charles Millar

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.