Do you mean something like this (I used an elisp block instead of a sql
block, but hopefully you get the idea):

#+name: src-block1
#+BEGIN_SRC emacs-lisp
'((1 2) (3 4))
#+END_SRC

#+RESULTS: src-block1
| 1 | 2 |
| 3 | 4 |

#+BEGIN_SRC python :var data=src-block1
print data
#+END_SRC

#+RESULTS:
: [[1, 2], [3, 4]]



If so, give your sql block a name, and use it as a variable in some other
block.

John

-----------------------------------
Professor John Kitchin
Doherty Hall A207F
Department of Chemical Engineering
Carnegie Mellon University
Pittsburgh, PA 15213
412-268-7803
@johnkitchin
http://kitchingroup.cheme.cmu.edu


On Tue, Jul 12, 2016 at 3:59 AM, Xi Shen <davidshe...@gmail.com> wrote:

> Hi,
>
> Say I have a sql babel block which outputs a table. Is there any way
> that I can reference the values in the output table in another babel
> block?
>
>

Reply via email to