aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman1999-02-19 04:27:18 +0000
committerRichard M. Stallman1999-02-19 04:27:18 +0000
commitc04bb32e2186e4fe4ee6a952e59efc15c28885eb (patch)
treeb26def46949bb83affebcfe4746def8fa634b88e
parentc7055d6660dc1e2d000bd7a3e28f6bd8872630c4 (diff)
downloademacs-c04bb32e2186e4fe4ee6a952e59efc15c28885eb.tar.gz
emacs-c04bb32e2186e4fe4ee6a952e59efc15c28885eb.zip
Set version to 1.4.1. Changed mail address to
alex@gnu.org. Mention the mailin listg sql.el@gnu.org. (sql-input-ring-separator): Doc fix. (sql-mode-syntax-table): double-dash starts comments is defined as ". 56" instead of ". 12b" for XEmacs. (sql-stop, sql-interactive-mode): Doc fixes. (sql-postgres): Queries for database and server, not just one. (sql-set-sqli-buffer): sql-set-sqli-hook must be quoted.
-rw-r--r--lisp/progmodes/sql.el46
1 files changed, 27 insertions, 19 deletions
diff --git a/lisp/progmodes/sql.el b/lisp/progmodes/sql.el
index c8b7a2e62eb..03b03b6a61d 100644
--- a/lisp/progmodes/sql.el
+++ b/lisp/progmodes/sql.el
@@ -2,9 +2,9 @@
2 2
3;; Copyright (C) 1998, 1999 Free Software Foundation, Inc. 3;; Copyright (C) 1998, 1999 Free Software Foundation, Inc.
4 4
5;; Author: Alex Schroeder <a.schroeder@bsiag.ch> 5;; Author: Alex Schroeder <alex@gnu.org>
6;; Maintainer: Alex Schroeder <a.schroeder@bsiag.ch> 6;; Maintainer: Alex Schroeder <alex@gnu.org>
7;; Version: 1.4.0 7;; Version: 1.4.1
8;; Keywords: comm languages processes 8;; Keywords: comm languages processes
9 9
10;; This file is part of GNU Emacs. 10;; This file is part of GNU Emacs.
@@ -26,8 +26,10 @@
26 26
27;;; Commentary: 27;;; Commentary:
28 28
29;; Please send me bug reports and bug fixes so that I can merge them 29;; Please send bug reports and bug fixes to the mailing list at
30;; into the master source. 30;; sql.el@gnu.org so that I can merge them into the master source. If
31;; you want to subscribe to the mailing list, send mail to
32;; sql.el-request@gnu.org with 'subscribe' in the subject line.
31 33
32;; You can get the latest version of this file from my homepage 34;; You can get the latest version of this file from my homepage
33;; <URL:http://www.geocities.com/TimesSquare/6120/emacs.html>. 35;; <URL:http://www.geocities.com/TimesSquare/6120/emacs.html>.
@@ -173,10 +175,13 @@ the input ring is initialized from a history file.
173 175
174This variable used to locally set `comint-input-ring-separator' when 176This variable used to locally set `comint-input-ring-separator' when
175reading or writing the history file. `comint-input-ring-separator' is 177reading or writing the history file. `comint-input-ring-separator' is
176new in Emacs 20.4; if your Emacs does not have it, setting 178not yet part of Emacs; if your Emacs does not have it, setting
177`sql-input-ring-separator' will have no effect. In that case multiline 179`sql-input-ring-separator' will have no effect. In that case multiline
178commands will be split into several commands when the input history is 180commands will be split into several commands when the input history is
179read, as if you had set `sql-input-ring-separator' to \"\\n\"." 181read, as if you had set `sql-input-ring-separator' to \"\\n\".
182
183The source code contains a link to a homepage that might have a patch
184for comint.el to download."
180 :type 'string 185 :type 'string
181 :group 'SQL) 186 :group 'SQL)
182 187
@@ -411,7 +416,9 @@ Used by `sql-rename-buffer'.")
411 (modify-syntax-entry ?/ ". 14" table) 416 (modify-syntax-entry ?/ ". 14" table)
412 (modify-syntax-entry ?* ". 23" table) 417 (modify-syntax-entry ?* ". 23" table)
413 ;; double-dash starts comment 418 ;; double-dash starts comment
414 (modify-syntax-entry ?- ". 12b" table) 419 (if (string-match "XEmacs\\|Lucid" emacs-version)
420 (modify-syntax-entry ?- ". 56" table)
421 (modify-syntax-entry ?- ". 12b" table))
415 ;; newline and formfeed end coments 422 ;; newline and formfeed end coments
416 (modify-syntax-entry ?\n "> b" table) 423 (modify-syntax-entry ?\n "> b" table)
417 (modify-syntax-entry ?\f "> b" table) 424 (modify-syntax-entry ?\f "> b" table)
@@ -710,7 +717,7 @@ If you call it from anywhere else, it sets the global copy of
710 (if new-buffer 717 (if new-buffer
711 (progn 718 (progn
712 (setq sql-buffer new-buffer) 719 (setq sql-buffer new-buffer)
713 (run-hooks sql-set-sqli-hook))))) 720 (run-hooks 'sql-set-sqli-hook)))))
714 721
715(defun sql-show-sqli-buffer () 722(defun sql-show-sqli-buffer ()
716 "Show the name of current SQLi buffer. 723 "Show the name of current SQLi buffer.
@@ -931,9 +938,7 @@ run.
931 938
932Variable `sql-input-ring-file-name' controls the initialisation of the 939Variable `sql-input-ring-file-name' controls the initialisation of the
933input ring history. `comint-input-ring-file-name' is temporarily bound 940input ring history. `comint-input-ring-file-name' is temporarily bound
934to `sql-input-ring-file-name' and `comint-input-ring-separator' is 941to `sql-input-ring-file-name' when reading the input history.
935temporarily bound to `sql-input-ring-separator' when reading the input
936history.
937 942
938Variables `comint-output-filter-functions', a hook, and 943Variables `comint-output-filter-functions', a hook, and
939`comint-scroll-to-bottom-on-input' and 944`comint-scroll-to-bottom-on-input' and
@@ -1001,8 +1006,7 @@ you entered, right above the output it created.
1001Writes the input history to a history file using 1006Writes the input history to a history file using
1002`comint-write-input-ring' and inserts a short message in the SQL buffer. 1007`comint-write-input-ring' and inserts a short message in the SQL buffer.
1003`comint-comint-input-ring-file-name' is temporarily bound to 1008`comint-comint-input-ring-file-name' is temporarily bound to
1004`sql-input-ring-file-name' and `comint-input-ring-separator' is 1009`sql-input-ring-file-name'.
1005temporarily bound to `sql-input-ring-separator'.
1006 1010
1007This function is a sentinel watching the SQL interpreter process. 1011This function is a sentinel watching the SQL interpreter process.
1008Sentinels will always get the two parameters PROCESS and EVENT." 1012Sentinels will always get the two parameters PROCESS and EVENT."
@@ -1359,7 +1363,7 @@ If buffer exists and a process is running, just switch to buffer
1359`*SQL*'. 1363`*SQL*'.
1360 1364
1361Interpreter used comes from variable `sql-postgres-program'. Login uses 1365Interpreter used comes from variable `sql-postgres-program'. Login uses
1362the variable `sql-database' as default, if set. 1366the variables `sql-database' and `sql-server' as default, if set.
1363 1367
1364The buffer is put in sql-interactive-mode, giving commands for sending 1368The buffer is put in sql-interactive-mode, giving commands for sending
1365input. See `sql-interactive-mode'. 1369input. See `sql-interactive-mode'.
@@ -1380,12 +1384,16 @@ Try to set `comint-output-filter-functions' like this:
1380 (interactive) 1384 (interactive)
1381 (if (comint-check-proc "*SQL*") 1385 (if (comint-check-proc "*SQL*")
1382 (pop-to-buffer "*SQL*") 1386 (pop-to-buffer "*SQL*")
1383 (sql-get-login 'database) 1387 (sql-get-login 'database 'server)
1384 (message "Login...") 1388 (message "Login...")
1385 ;; username and password are ignored. 1389 ;; username and password are ignored.
1386 (if (string= "" sql-database) 1390 (let ((params))
1387 (set-buffer (make-comint "SQL" sql-postgres-program nil)) 1391 (if (not (string= "" sql-database))
1388 (set-buffer (make-comint "SQL" sql-postgres-program nil sql-database))) 1392 (setq params (append (list sql-database) params)))
1393 (if (not (string= "" sql-server))
1394 (setq params (append (list "-h" sql-server) params)))
1395 (set-buffer (apply 'make-comint "SQL" sql-postgres-program
1396 nil params)))
1389 (setq sql-prompt-regexp "^.*> *") 1397 (setq sql-prompt-regexp "^.*> *")
1390 (setq sql-prompt-length 5) 1398 (setq sql-prompt-length 5)
1391 ;; This is a lousy hack to prevent psql from truncating it's output 1399 ;; This is a lousy hack to prevent psql from truncating it's output