I am trying to insert a column in a table in org-mode and I get the content moved.
For example, I have this table:

| Name   | Age |
|--------+-----|
| Tarzan |  40 |
| Jane   |  39 |

Now I want to insert a column between Name and Age.
So I add a pipe (|) just after Name:

| Name  | | Age |
|--------+-----|
| Tarzan |  40 |
| Jane   |  39 |

And the press TAB.
I get this:

| Name   |    | Age |
|--------+----+-----|
| Tarzan | 40 |     |
| Jane   | 39 |     |

While what I would expect is:

| Name   |    | Age |
|--------+----+-----|
| Tarzan |    |  40 |
| Jane   |    |  39 |

It seems kind of simple to fix manually for that table, but... I haven't told you all the story.
In the real table I have Boy, Cheeta, Cheeta's family, the herd of elephants, lions, tigers, crocodiles, etc... and all the psychological relationships between them...

Is there a way to avoid that column content move?

Just positioning at the column:

       cursor here
          |
          V
| Name   |■Age |
|--------+-----|
| Tarzan |  40 |
| Jane   |  39 |

and using M-S-right (org-table-insert-column) makes it:

| Name   |   | Age |
|--------+---+-----|
| Tarzan |   |  40 |
| Jane   |   |  39 |

From the org-mode manual:

M-S-<right>     (org-table-insert-column)
Insert a new column to the left of the cursor position. 

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

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