6

When I press C-cC-xC-r to print the clock report I get something like the following:

Clock summary at [2014-11-05 Wed 13:33]

| Headline     | Time   |
|--------------+--------|
| *Total time* | *0:01* |
|--------------+--------|
| test         | 0:01   |

The problem is that I have many entries at the same level. Like:

     * test
     CLOCK: [2014-11-05 Wed 13:13]--[2014-11-05 Wed 13:13] =>  0:00
     CLOCK: [2014-11-05 Wed 13:08]--[2014-11-05 Wed 13:09] =>  0:01
     CLOCK: [2014-11-05 Wed 13:08]--[2014-11-05 Wed 13:08] =>  0:00

Org-mode only recognizes details in sub-trees like:

* Haha
  #+BEGIN: clocktable :maxlevel 2 :scope subtree :timestamp t
  Clock summary at [2014-11-05 Wed 13:44]

  | Timestamp            | Headline     | Time   |      |
  |----------------------+--------------+--------+------|
  |                      | *Total time* | *0:03* |      |
  |----------------------+--------------+--------+------|
  |                      | Haha         | 0:03   |      |
  | 2014-11-05 Wed 13:40 | \__ test     |        | 0:03 |
  #+END:

Is there a way to print all the details within the same level, that is, all the clock entries and the length of each period?

  • I'm afraid not - AFAIU the point of clock tables is aggregating these data. What is your use case? Why do you want this? Maybe you are looking for a specialized, custom exporter? – mbork Nov 5 '14 at 21:04
  • Nothing big. Sometimes I have two time periods inside one headline, and I want to print the clocktable of that headline (inside the headline itself) showing both periods. Instead, org only shows the total. – Husain Nov 5 '14 at 21:23
3

No, unfortunatley there is no way to do so directly. The idea of clock table is to aggregate data.

But fear not, you have two ways to solve the dillema: (That I can think of? there may be others).

1) Use step by day:

Insert the following into your report line:

:step day   

e.g: [edit, below not tested, see comment for working example]

 #+BEGIN: clocktable :step day  :maxlevel 2 :scope subtree :timestamp t

Then time reports will be split by day. By week is also an option, (The default shows total, the weekly shows by/week data.

2) If you want it more granular than by day, then one option eaybe column view with sub-tasks might be the cup of tea that you've been longing for.

e.g

* Make Pizza
** Buy groceries
** Speak with the italian neighbour 
** prepare base 
** put things on top
** bake 

Then set an estimate on each sub-heading, clock in/out what you worked on. Then hover over * Make Pizzaa and press C-c-x-c and you will see a column with info on individual tasks.

It will look something like so: http://www.devalot.com/assets/articles/2008/07/project-planning/columns.jpg

What ever you do, never forget: Just stay calm and org-on.

  • 1
    The first solution doesn't work - you need to specify :block or equivalent. #+BEGIN: clocktable :maxlevel 2 :scope subtree :step day :block thisyear :stepskip0 is more useful, producing a report a day, but only for those days where there is non-zero time. – Andrew Swann Jun 4 '15 at 10:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.