From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nicolas Goaziou Subject: Re: [PATCH] ob-sql.el: Support sqlcmd and cygwin environment Date: Wed, 15 Jun 2016 18:49:30 +0200 Message-ID: <87inxaz9b9.fsf@saiph.selenimh> References: <87r3c4em1r.fsf@saiph.selenimh> <87a8isdso8.fsf@saiph.selenimh> <87vb1c0yyn.fsf@saiph.selenimh> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:45171) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bDE0o-0004cp-Tc for Emacs-orgmode@gnu.org; Wed, 15 Jun 2016 12:49:55 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bDE0k-0005Rx-RC for Emacs-orgmode@gnu.org; Wed, 15 Jun 2016 12:49:54 -0400 Received: from relay3-d.mail.gandi.net ([217.70.183.195]:44420) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bDE0k-0005RL-KQ for Emacs-orgmode@gnu.org; Wed, 15 Jun 2016 12:49:50 -0400 In-Reply-To: (Xi Shen's message of "Wed, 15 Jun 2016 04:01:06 +0000") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: Xi Shen Cc: "Emacs-orgmode@gnu.org" Hello, Xi Shen writes: > I suppose I should put the news entry to ./etc/ORG-NEWS file, but into > which version? I created below entry, please take look and let me know > where do you want me to put it. I'd say Version 9.0 > New features > Babel or Version 9.0 > Miscellaneous > *** Improved support to Microsoft SQL Server in =ob-sql.el= > =ob-sql.el= library removes support to the ~msosql~ engine which uses > the deprecated =osql= command line tool, and replaces it with ~mssql~ > engine which uses the =sqlcmd= command line tool. Use with properties > like this: > > #+BEGIN_EXAMPLE > :engine mssql > :dbhost > :dbuser > :dbpassword > :database > #+END_EXAMPLE > > If you want to use the *trusted connection* feature, omit *both* the > =dbuser= and =dbpassword= properties and add =cmdline -E= to the > properties. > > If your Emacs is running in a Cygwin environment, the =ob-sql.el= > library can pass the converted path to the =sqlcmd= tool. It looks good. > I checked the code and it does not quote the arguments for me. It is a safe > manner in Windows to always quote the path. So I will keep it. Fair enough. > I have a question. Currently the table generated by mssql engine has the > "affected rows" append to the end, like this. > > | memberid | username | xx | flags | > |-------------------+----------+------+-------| > | 1 | GPL | Indo | NULL | > | 2 | GPL | Indo | NULL | > | | | | | > | (2 rows affected) | | | | > > I personally prefer to remove it. Do you or the org community has a > preference about this? Maybe I should keep the behavior align with other > engines? I lean towards removing it, too. I doesn't give useful feedback. We can always insert it back later if it introduces unwanted side-effects. Thank you. Regards, -- Nicolas Goaziou