Re: [O] [Orgmode] Babel sql code block issue and patch proposal

2011-03-07 Thread Alain Clément
Hi Eric, Thank you so much, your "fearless development" is great and very appreciated! Best regards, - Alain 2011/3/7 Eric Schulte > To be honest, I don't have any overly motivating reasons for passing the > file name to mysql rather than piping the contents of the file. Aside > from consistenc

Re: [O] [Orgmode] Babel sql code block issue and patch proposal

2011-03-07 Thread Eric Schulte
To be honest, I don't have any overly motivating reasons for passing the file name to mysql rather than piping the contents of the file. Aside from consistency with the other SQL engines, the nagging feeling that things are the way they are for a reason, and a healthy fear of the new and unknown.

Re: [O] [Orgmode] Babel sql code block issue and patch proposal

2011-03-07 Thread Alain Clément
Hi Eric, Thanks for your message and sorry for the delay. Actually, escaping characters with backslashes is the problem within mysql when the =SOURCE= command is invoqued. To believe the forums, it seems that this difficulty is well known among mysql users. The suggested solution there consists in

Re: [O] [Orgmode] Babel sql code block issue and patch proposal

2011-03-03 Thread Eric Schulte
Hi Alain, Would the following work (escaping "-"s with a backslash)? #+begin_src diff diff --git a/lisp/ob-sql.el b/lisp/ob-sql.el index 364070e..838f013 100644 --- a/lisp/ob-sql.el +++ b/lisp/ob-sql.el @@ -73,7 +73,9 @@ This function is called by `org-babel-execute-src-block'."

Re: [O] [Orgmode] Babel sql code block issue and patch proposal

2011-03-03 Thread Alain Clément
Hi Eric, Thanks for your prompt answer! Actually, it doesn't work since mysql interprets backslashes as options, even between quotes. The value of my `org-babel-temporary-directory' is "/var/folders/9E/9EMu+g0oHBSrq-h9sX6i1U+++TM/-Tmp-/babel-86766893", but "+"'s are escaped with a backslash at som

[O] [Orgmode] Babel sql code block issue and patch proposal

2011-03-03 Thread Alain Clément
Hi everyone, The =org-babel-temp-file= string seems to be escaped with backslashes on some platforms (like MacOSX), which is not very appreciated by the =mysql -e= command. I suggest the following patch for =ob-sql.el= (Org-mode Version 7.4 (release_7.4.590.g85d4d)): 74c74 < (

Re: [O] [Orgmode] Babel sql code block issue and patch proposal

2011-03-03 Thread Eric Schulte
Hi Alain, Does the following alternative fix work for you? #+begin_src diff Changes in HEAD Modified lisp/ob-sql.el diff --git a/lisp/ob-sql.el b/lisp/ob-sql.el index 364070e..604d444 100644 --- a/lisp/ob-sql.el +++ b/lisp/ob-sql.el @@ -71,7 +71,7 @@ This function is called