GNU bug report logs - #24483
25.1; sql-mode error due to nil prompt-cont-regexp

Previous Next

Package: emacs;

Reported by: Michael Kleehammer <michael <at> kleehammer.com>

Date: Tue, 20 Sep 2016 17:50:01 UTC

Severity: normal

Merged with 27586

Found in version 25.1

Fixed in version 27.0.50

Done: Michael Mauger <mmauger <at> protonmail.com>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 24483 in the body.
You can then email your comments to 24483 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#24483; Package emacs. (Tue, 20 Sep 2016 17:50:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Michael Kleehammer <michael <at> kleehammer.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Tue, 20 Sep 2016 17:50:01 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Michael Kleehammer <michael <at> kleehammer.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 25.1; sql-mode error due to nil prompt-cont-regexp
Date: Tue, 20 Sep 2016 12:48:56 -0500
It looks like sql-interactive-remove-continuation-prompt needs to explicitly check for a nil sql-prompt-cont-regexp, which is the default value for some SQL products.

In particular, this line marked with an arrow on the left needs a guard:

    (when (and comint-prompt-regexp
               (or (> (length (or sql-preoutput-hold "")) 0)
                   (> (or sql-output-newline-count 0) 0)
                   (not (or (string-match sql-prompt-regexp oline)
    -->                     (string-match sql-prompt-cont-regexp oline)))))

In my case I am using a custom "SQL product" for a SQL Server command
line utility which prints "Connected to xyzzy\n" on startup but there
are some standard "products" that also don't have a prompt-cont-regexp
set.

It should be easy to reproduce using "ansi", but here is how I
reproduced it with PostgreSQL:

1) Set the PostgreSQL regexp to nil:

    (sql-set-product-feature 'postgres :prompt-cont-regexp nil)

2) Make sure psql prints something on connect.  I have this in my
   ~/.psqlrc:

    \pset null ¤

When you open a connection using sql-postgres you'll get:

    error in process filter: sql-interactive-remove-continuation-prompt: Wrong type argument: stringp, nil
    error in process filter: Wrong type argument: stringp, nil

This is new in 25.1.  I used 24.5 and did not have this issue. 

Thanks,
Michael Kleehammer
michael <at> kleehammer.com


In GNU Emacs 25.1.1 (x86_64-apple-darwin13.4.0, NS appkit-1265.21 Version 10.9.5 (Build 13F1911))
 of 2016-09-17 built on builder10-9.porkrind.org
Windowing system distributor 'Apple', version 10.3.1504
Configured using:
 'configure --with-ns '--enable-locallisppath=/Library/Application
 Support/Emacs/${version}/site-lisp:/Library/Application
 Support/Emacs/site-lisp''

Configured features:
NOTIFY ACL GNUTLS LIBXML2 ZLIB TOOLKIT_SCROLL_BARS NS

Important settings:
  value of $LANG: en_US.UTF8
  locale-coding-system: utf-8-unix

Major mode: Emacs-Lisp

Minor modes in effect:
  diff-auto-refine-mode: t
  magit-auto-revert-mode: t
  global-git-commit-mode: t
  shell-dirtrack-mode: t
  ws-butler-global-mode: t
  ws-butler-mode: t
  yas-global-mode: t
  yas-minor-mode: t
  ido-vertical-mode: t
  flx-ido-mode: t
  ido-everywhere: t
  global-undo-tree-mode: t
  undo-tree-mode: t
  projectile-global-mode: t
  projectile-mode: t
  recentf-mode: t
  pcre-mode: t
  drag-stuff-global-mode: t
  drag-stuff-mode: t
  delete-selection-mode: t
  cua-mode: t
  highlight-changes-visible-mode: t
  show-paren-mode: t
  global-linum-mode: t
  linum-mode: t
  override-global-mode: t
  global-eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  column-number-mode: t
  line-number-mode: t
  transient-mark-mode: t

Recent messages:
buf: nil
Login...done
w #<window 21 on sqlwchar.cpp>
Quit
uncompressing sql.el.gz...done
Mark saved where search started
Mark set
Mark saved where search started [4 times]
Mark set
Quit

Load-path shadows:
/Users/mkleehammer/.emacs.d/misc/expand-region/web-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/web-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/the-org-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/the-org-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/text-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/text-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/sml-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/sml-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/ruby-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/ruby-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/python-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/python-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/python-el-fgallina-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/python-el-fgallina-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/python-el-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/python-el-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/octave-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/octave-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/nxml-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/nxml-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/latex-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/latex-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/jsp-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/jsp-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/js2-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/js2-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/js-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/js-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/html-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/html-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/feature-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/feature-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/expand-region hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/expand-region
/Users/mkleehammer/.emacs.d/misc/expand-region/expand-region-pkg hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/expand-region-pkg
/Users/mkleehammer/.emacs.d/misc/expand-region/expand-region-custom hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/expand-region-custom
/Users/mkleehammer/.emacs.d/misc/expand-region/expand-region-core hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/expand-region-core
/Users/mkleehammer/.emacs.d/misc/expand-region/erlang-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/erlang-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/er-basic-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/er-basic-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/enh-ruby-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/enh-ruby-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/css-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/css-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/cperl-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/cperl-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/clojure-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/clojure-mode-expansions
/Users/mkleehammer/.emacs.d/misc/expand-region/cc-mode-expansions hides /Users/mkleehammer/.emacs.d/elpa/expand-region-0.10.0/cc-mode-expansions
/Users/mkleehammer/.emacs.d/misc/undo-tree hides /Users/mkleehammer/.emacs.d/elpa/undo-tree-0.6.5/undo-tree
/Users/mkleehammer/.emacs.d/misc/python hides /Applications/Emacs.app/Contents/Resources/lisp/progmodes/python
/Users/mkleehammer/.emacs.d/elpa/seq-2.16/seq hides /Applications/Emacs.app/Contents/Resources/lisp/emacs-lisp/seq

Features:
(shadow sort mail-extr emacsbug sendmail pp timezone parse-time
jka-compr shr-color color network-stream nsm starttls url-http tls
gnutls url-gw url-auth eww mm-url gnus gnus-ems nnheader url-queue shr
dom browse-url less-css-mode css-mode smie derived wdired web-mode
disp-table dabbrev misearch multi-isearch smex magit-blame magit-stash
magit-bisect magit-remote magit-commit magit-sequence magit magit-apply
magit-wip magit-log magit-diff smerge-mode diff-mode magit-core
magit-autorevert autorevert filenotify magit-process magit-popup
magit-mode magit-git crm magit-section magit-utils git-commit log-edit
message rfc822 mml mml-sec epg mm-decode mm-bodies mm-encode mail-parse
rfc2231 rfc2047 rfc2045 ietf-drums mailabbrev mail-utils gmm-utils
mailheader pcvs-util add-log with-editor async-bytecomp async python
tramp-sh tramp tramp-compat tramp-loaddefs trampver shell format-spec
dired-aux server sunshine url-cache url url-proxy url-privacy url-expand
url-methods url-history url-cookie url-domsuf url-util url-parse
auth-source gnus-util mm-util help-fns mail-prsvr password-cache
url-vars mailcap cal-china lunar solar cal-dst cal-bahai cal-islam
cal-hebrew holidays hol-loaddefs appt diary-lib diary-loaddefs cal-menu
calendar cal-loaddefs sql view tea-time pcomplete esh-var esh-io esh-cmd
esh-opt esh-ext esh-proc esh-arg esh-groups eshell esh-module esh-mode
esh-util js2-mode etags xref project eieio eieio-core js sgml-mode
cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles cc-align cc-engine
cc-vars cc-defs imenu ws-butler whitespace yasnippet cl browse-kill-ring
avy ido-vertical-mode ido-ubiquitous cl-seq ido-completing-read+
cus-edit flx-ido flx ido undo-tree iedit iedit-lib flycheck json map
find-func subr-x projectile ibuf-ext ibuffer dash thingatpt recentf
tree-widget pcre2el rxt cl-macs re-builder rx drag-stuff
whole-line-or-region align2 edmacro kmacro wgrep reveal-in-osx-finder
dired-x dired exec-path-from-shell delsel cua-base hydra lv hilit-chg
wid-edit paren avoid linum zenburn-theme use-package diminish bind-key
easy-mmode finder-inf advice info package epg-config seq byte-opt gv
bytecomp byte-compile cl-extra help-mode easymenu cconv cl-loaddefs
pcase cl-lib grep compile comint ansi-color ring cus-start cus-load
time-date mule-util tooltip eldoc electric uniquify ediff-hook vc-hooks
lisp-float-type mwheel ns-win ucs-normalize term/common-win tool-bar dnd
fontset image regexp-opt fringe tabulated-list newcomment elisp-mode
lisp-mode prog-mode register page menu-bar rfn-eshadow timer select
scroll-bar mouse jit-lock font-lock syntax facemenu font-core frame
cl-generic cham georgian utf-8-lang misc-lang vietnamese tibetan thai
tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian
slovak czech european ethiopic indian cyrillic chinese charscript
case-table epa-hook jka-cmpr-hook help simple abbrev minibuffer
cl-preloaded nadvice loaddefs button faces cus-face macroexp files
text-properties overlay sha1 md5 base64 format env code-pages mule
custom widget hashtable-print-readable backquote kqueue cocoa ns
multi-tty make-network-process emacs)

Memory information:
((conses 16 764072 122496)
 (symbols 48 50260 0)
 (miscs 40 1811 957)
 (strings 32 147544 5627)
 (string-bytes 1 4555893)
 (vectors 16 105142)
 (vector-slots 8 2292082 293693)
 (floats 8 12056 11134)
 (intervals 56 19325 3290)
 (buffers 976 43))





Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#24483; Package emacs. (Fri, 24 Feb 2017 19:54:02 GMT) Full text and rfc822 format available.

Message #8 received at 24483 <at> debbugs.gnu.org (full text, mbox):

From: Pablo Mercader Alcántara <programingfrik <at> gmail.com>
To: 24483 <at> debbugs.gnu.org
Subject: bug#24483: 25.1; sql-mode error due to nil prompt-cont-regexp
Date: Fri, 24 Feb 2017 15:53:44 -0400
I'm having this same problem using ms-sql-server. I've been triying to
make it work playing with edebug but haven't made any progress, if I
find a way to work around this or something I'll place it here.

In GNU Emacs 25.1.1 (x86_64-w64-mingw32)
 of 2016-11-15 built on LAPHROAIG
Windowing system distributor 'Microsoft Corp.', version 10.0.10240
Configured using:
 'configure --without-dbus --without-compress-install 'CFLAGS=-O2
 -static -g3''

Configured features:
XPM JPEG TIFF GIF PNG RSVG SOUND NOTIFY ACL GNUTLS LIBXML2 ZLIB
TOOLKIT_SCROLL_BARS

Important settings:
  value of $LANG: ENU
  locale-coding-system: cp1252

Major mode: Emacs-Lisp

Minor modes in effect:
  diff-auto-refine-mode: t
  shell-dirtrack-mode: t
  yas-global-mode: t
  yas-minor-mode: t
  tooltip-mode: t
  global-eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t

Recent messages:

Result: "(1 row affected)\nMsg 2812, Level 16, State 62, Server
INTRANETDB, Line 1\nCould not find stored procedure 'l'.\n
\n ----------- \n           1 \n\n"

Wrong type argument: stringp, nil

error in process filter: edebug-signal: Wrong type argument: stringp, nil
error in process filter: Wrong type argument: stringp, nil
Quit [2 times]
Mark set [2 times]
Mark saved where search started

Load-path shadows:
c:/Users/pmercader/AppData/Roaming/.emacs.d/elpa/cygwin-mount-20131111.1346/cygwin-mount
hides d:/share/emacs/share/emacs/site-lisp/cygwin/cygwin-mount

Features:
(shadow sort mail-extr emacsbug message dired rfc822 mml mml-sec epg
mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils
mailheader sendmail rfc2047 rfc2045 ietf-drums mail-utils edebug debug
eieio-opt speedbar sb-image ezimage dframe magit-utils dash rect vc-git
diff-mode easy-mmode python tramp-sh tramp tramp-compat auth-source
eieio eieio-core cl-macs gnus-util mm-util mail-prsvr password-cache
tramp-loaddefs trampver ucs-normalize shell pcomplete format-spec advice
json map find-func help-fns sql view thingatpt misearch multi-isearch
vc-dispatcher vc-svn nxml-uchnm rng-xsd xsd-regexp rng-cmpct rng-nxml
rng-valid rng-loc rng-uri rng-parse nxml-parse rng-match rng-dt rng-util
rng-pttrn nxml-ns nxml-mode nxml-outln nxml-rap nxml-util nxml-glyph
nxml-enc xmltok edmacro kmacro cus-edit cus-start cus-load wid-edit
setup-cygwin cygwin-mount ange-ftp comint ansi-color ring cl-seq
yasnippet misterioso-theme finder-inf info package epg-config windmove
ido seq byte-opt gv bytecomp byte-compile cl-extra help-mode easymenu
cconv cl-loaddefs pcase cl-lib time-date mule-util tooltip eldoc
electric uniquify ediff-hook vc-hooks lisp-float-type mwheel dos-w32
ls-lisp disp-table w32-win w32-vars term/common-win tool-bar dnd fontset
image regexp-opt fringe tabulated-list newcomment elisp-mode lisp-mode
prog-mode register page menu-bar rfn-eshadow timer select scroll-bar
mouse jit-lock font-lock syntax facemenu font-core frame cl-generic cham
georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao
korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech
european ethiopic indian cyrillic chinese charscript case-table epa-hook
jka-cmpr-hook help simple abbrev minibuffer cl-preloaded nadvice
loaddefs button faces cus-face macroexp files text-properties overlay
sha1 md5 base64 format env code-pages mule custom widget
hashtable-print-readable backquote w32notify w32 multi-tty
make-network-process emacs)

Memory information:
((conses 16 403940 43396)
 (symbols 56 32319 0)
 (miscs 48 187 569)
 (strings 32 61799 11981)
 (string-bytes 1 1812321)
 (vectors 16 49325)
 (vector-slots 8 907506 34336)
 (floats 8 863 484)
 (intervals 56 23167 362)
 (buffers 976 33))




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#24483; Package emacs. (Mon, 29 May 2017 16:53:02 GMT) Full text and rfc822 format available.

Message #11 received at 24483 <at> debbugs.gnu.org (full text, mbox):

From: Nikolay Kudryavtsev <nikolay.kudryavtsev <at> gmail.com>
To: Pablo Mercader Alcántara <programingfrik <at> gmail.com>,
 24483 <at> debbugs.gnu.org
Subject: Re: bug#24483: 25.1; sql-mode error due to nil prompt-cont-regexp
Date: Mon, 29 May 2017 19:52:36 +0300
Hello, Pablo.

I don't think you have the same bug as OP.

In your case it seems that you're trying to execute some stored 
procedure that does not exist and Emacs fails at parsing the reply.

Can you try adding:

(add-to-list 'process-coding-system-alist '("sqlcmd" . cp866))

to your init and see if anything changes. Also, you're using sqlcmd, right?

-- 
Best Regards,
Nikolay Kudryavtsev





Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#24483; Package emacs. (Mon, 29 May 2017 21:11:01 GMT) Full text and rfc822 format available.

Message #14 received at 24483 <at> debbugs.gnu.org (full text, mbox):

From: Pablo Mercader Alcántara <programingfrik <at> gmail.com>
To: Nikolay Kudryavtsev <nikolay.kudryavtsev <at> gmail.com>
Cc: 24483 <at> debbugs.gnu.org
Subject: Re: bug#24483: 25.1; sql-mode error due to nil prompt-cont-regexp
Date: Mon, 29 May 2017 17:10:34 -0400
[Message part 1 (text/plain, inline)]
Hello Nikolay Kudryavtsev ! thanks for your interest in this little problem.

I do think it is the same problem. I think that emacs tries to erase the
sql prompt from the response and fails to do it. I'm getting the same
problem that OP describes, when I open an interactive sql buffer and try to
execute anything emacs answers with the error "Wrong type argument:
stringp, nil" and no clue of the actual data. The moment in which I decided
to report the bug might be while executing an stored procedure that doesn't
exist, but this problem shows every time I execute ANYTHING, even a simple
"select 1\ngo\n". You can see by your self that the "Wrong type argument"
error is in the emacs output in my mail.

To tell you the truth I did find a little workaround, that's why I didn't
bother with the problem to much. This bug is in my "todo" list but I'm a
little bussy to try to understand it and make a proper repair. What I did
to workaround it using the ideas provided in the mail of the OP and
watching what was happening in edebug, was to modify sql-product-alist in
sql.el, the "prompt-cont-regexp" in the "ms" product was not even there, so
I put the property and set it to " " ( <- a blank space) and that did the
trick. It now shows the results but when showing those ms-sql-server
results it always eats some spaces in the first column making the rows and
the head of the rows misaligned.

Also as OP said I didn't had this problem in the previous version (24.5)
either.

I'm using osql, and I'm already using cp850 with it, I think that's the
right encoding I should use because its what the command prompt of windows
is using. Why do you think I should use cp866.

Thanks again! I hope this information helps.


2017-05-29 12:52 GMT-04:00 Nikolay Kudryavtsev <
nikolay.kudryavtsev <at> gmail.com>:

> Hello, Pablo.
>
> I don't think you have the same bug as OP.
>
> In your case it seems that you're trying to execute some stored procedure
> that does not exist and Emacs fails at parsing the reply.
>
> Can you try adding:
>
> (add-to-list 'process-coding-system-alist '("sqlcmd" . cp866))
>
> to your init and see if anything changes. Also, you're using sqlcmd, right?
>
> --
> Best Regards,
> Nikolay Kudryavtsev
>
>
[Message part 2 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#24483; Package emacs. (Mon, 29 May 2017 21:51:01 GMT) Full text and rfc822 format available.

Message #17 received at 24483 <at> debbugs.gnu.org (full text, mbox):

From: Nikolay Kudryavtsev <nikolay.kudryavtsev <at> gmail.com>
To: Pablo Mercader Alcántara <programingfrik <at> gmail.com>
Cc: 24483 <at> debbugs.gnu.org
Subject: Re: bug#24483: 25.1; sql-mode error due to nil prompt-cont-regexp
Date: Tue, 30 May 2017 00:50:22 +0300
Oh, sorry for the cp866 suggestion, my bad, cp850 is probably right for you.

If you're using osql, can you try switching to sqlcmd? Osql had been 
considered deprected by Microsoft for many years. Sqlcmd is freely 
downloadable and should be usable with any more or less modern version 
of SQL Server. The configuration for it that I use looks like this:

(setq sql-ms-program "sqlcmd"
          sql-ms-options (quote ("-W" "-s" "|" "-I")))

-- 
Best Regards,
Nikolay Kudryavtsev





Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#24483; Package emacs. (Mon, 05 Jun 2017 15:32:01 GMT) Full text and rfc822 format available.

Message #20 received at 24483 <at> debbugs.gnu.org (full text, mbox):

From: Pablo Mercader Alcántara <programingfrik <at> gmail.com>
To: 24483 <at> debbugs.gnu.org
Subject: Re: bug#24483: 25.1; sql-mode error due to nil prompt-cont-regexp
Date: Mon, 5 Jun 2017 11:31:13 -0400
[Message part 1 (text/plain, inline)]
Ok, I tried using "sqlcmd" instead of "osql" and the problem remains. Also
tried using MySQL instead of MS-SQL-Server to see if I could reproduce the
problem, and it has a similar problem, doesn't show any results to any
query I write, but doesn't spit the "Wrong type argument: stringp, nil"
message.

So the problem is not the executable program used to talk to the database.
I'm still beating to a problem in sql.el.

Thanks for your help!


2017-05-29 17:50 GMT-04:00 Nikolay Kudryavtsev <
nikolay.kudryavtsev <at> gmail.com>:

> Oh, sorry for the cp866 suggestion, my bad, cp850 is probably right for
> you.
>
> If you're using osql, can you try switching to sqlcmd? Osql had been
> considered deprected by Microsoft for many years. Sqlcmd is freely
> downloadable and should be usable with any more or less modern version of
> SQL Server. The configuration for it that I use looks like this:
>
> (setq sql-ms-program "sqlcmd"
>           sql-ms-options (quote ("-W" "-s" "|" "-I")))
>
>
> --
> Best Regards,
> Nikolay Kudryavtsev
>
>
[Message part 2 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#24483; Package emacs. (Mon, 05 Jun 2017 22:26:01 GMT) Full text and rfc822 format available.

Message #23 received at 24483 <at> debbugs.gnu.org (full text, mbox):

From: Nikolay Kudryavtsev <nikolay.kudryavtsev <at> gmail.com>
To: Pablo Mercader Alcántara <programingfrik <at> gmail.com>
Cc: 24483 <at> debbugs.gnu.org
Subject: Re: bug#24483: 25.1; sql-mode error due to nil prompt-cont-regexp
Date: Tue, 6 Jun 2017 01:25:12 +0300
Hello, Pablo.

It's not clear from your letter whether you still have an error with 
prompt-cont-regexp when using sqlcmd. If so, could you please set 
debug-on-error to t and paste the debug log here.

For mysql I use (setq sql-mysql-options '("-C" "-f" "-t" "-n")). Also 
don't forget the statement terminator there: either put ";" or "\go" at 
the end query.

-- 
Best Regards,
Nikolay Kudryavtsev





Merged 24483 27586. Request was from Glenn Morris <rgm <at> gnu.org> to control <at> debbugs.gnu.org. (Wed, 05 Jul 2017 16:58:01 GMT) Full text and rfc822 format available.

bug marked as fixed in version 27.0.50, send any further explanations to 24483 <at> debbugs.gnu.org and Michael Kleehammer <michael <at> kleehammer.com> Request was from Michael Mauger <mmauger <at> protonmail.com> to control <at> debbugs.gnu.org. (Sun, 21 Apr 2019 06:03:02 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sun, 19 May 2019 11:24:07 GMT) Full text and rfc822 format available.

This bug report was last modified 4 years and 354 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.