From mboxrd@z Thu Jan 1 00:00:00 1970 From: Xi Shen Subject: Proposal to use sqlcmd for connecting to SQL Server Date: Wed, 08 Jun 2016 07:04:09 +0000 Message-ID: Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=94eb2c04f8ea0732190534beea3d Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:51080) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bAXXJ-0006yk-8N for Emacs-orgmode@gnu.org; Wed, 08 Jun 2016 03:04:22 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bAXXH-0001cg-5l for Emacs-orgmode@gnu.org; Wed, 08 Jun 2016 03:04:20 -0400 Received: from mail-oi0-x230.google.com ([2607:f8b0:4003:c06::230]:33570) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bAXXG-0001cc-VV for Emacs-orgmode@gnu.org; Wed, 08 Jun 2016 03:04:19 -0400 Received: by mail-oi0-x230.google.com with SMTP id k23so314073793oih.0 for ; Wed, 08 Jun 2016 00:04:18 -0700 (PDT) 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: "Emacs-orgmode@gnu.org" --94eb2c04f8ea0732190534beea3d Content-Type: text/plain; charset=UTF-8 Hi, I tried the use the msosql engine in org-mode, but it cannot format the result into a table. I think MS has made some change that the output of the command is not compatible with org-mode. More specifically, the output add "1> 2> 3> 4> " to the begging and break the table formatting. I saw this result on Windows 7 with osql 10.50.1600.1. However, I found that the output of "sqlcmd" can be formatted into a table in org-mode correctly without any trick. osql and sqlcmd take similar command arguments, with sqlcmd has more options. I think it is safe to simply replace the "osql" command into "sqlcmd" command in the ob-sql.el file. The only major difference between these two tools are: osql uses ODBC to connect to the server; while sqlcmd uses the fancy native client to connect to the server. I would like to hear ideas/suggestions about this. Thanks, David -- Thanks, David S. --94eb2c04f8ea0732190534beea3d Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hi,

I tried the use the msosql engine i= n org-mode, but it cannot format the result into a table. I think MS has ma= de some change that the output of the command is not compatible with org-mo= de. More specifically, the output add "1> 2> 3> 4> =C2=A0&= quot; to the begging and break the table formatting. I saw this result on W= indows 7 with osql 10.50.1600.1.

However, I found = that the output of "sqlcmd" can be formatted into a table in org-= mode correctly without any trick.

osql and sqlcmd = take similar command arguments, with sqlcmd has more options. I think it is= safe to simply replace the "osql" command into "sqlcmd"= ; command in the ob-sql.el file.

The only major di= fference between these two tools are: osql uses ODBC to connect to the serv= er; while sqlcmd uses the fancy native client to connect to the server.

I would like to hear ideas/suggestions about this.


Thanks,
David
--

Thanks,
David S.

--94eb2c04f8ea0732190534beea3d--