* Eric S Fraga <e.fr...@ucl.ac.uk> [2020-11-24 12:46]: > On Tuesday, 24 Nov 2020 at 12:00, Jean Louis wrote: > > Can I automated the execution of Babel code upon opening of the Org > > file? > > You can, by using file local variables. For instance, for some files, I > do this: > > #+begin_src org > ,* local variables :noexport: > # Local Variables: > # eval: (org-sbe "startup") > # End: > #+end_src
I have got it to work as I had to name the source block. It does evaluates and I get the result in the message buffer, but it does not expands in the Org buffer. That is what I wish to find out how. ** Stages #+NAME: stages #+BEGIN_SRC sql :engine postgresql :exports results :results replace SELECT 1 AS table; #+END_SRC # Local Variables: # eval: (org-sbe "stages") # End: