diff options
| author | Glenn Morris | 2012-02-07 23:54:09 -0800 |
|---|---|---|
| committer | Glenn Morris | 2012-02-07 23:54:09 -0800 |
| commit | 34e8a2da58131aa0e30f2b7427829b41d2997f10 (patch) | |
| tree | 3364592f7d78c633bd558444ffce2ae0d9f6133b /lisp/progmodes/sql.el | |
| parent | 14a1f3806c3d189d0dd10db863320fa36d428fd1 (diff) | |
| download | emacs-34e8a2da58131aa0e30f2b7427829b41d2997f10.tar.gz emacs-34e8a2da58131aa0e30f2b7427829b41d2997f10.zip | |
Shorten SQL mode NEWS entry, moving more details to doc strings
* lisp/progmodes/sql.el (sql-port, sql-connection-alist, sql-list-all)
(sql-list-table): Doc fixes.
* etc/NEWS: Related edits.
Diffstat (limited to 'lisp/progmodes/sql.el')
| -rw-r--r-- | lisp/progmodes/sql.el | 34 |
1 files changed, 15 insertions, 19 deletions
diff --git a/lisp/progmodes/sql.el b/lisp/progmodes/sql.el index 2e59d8f8517..f8f62d113e6 100644 --- a/lisp/progmodes/sql.el +++ b/lisp/progmodes/sql.el | |||
| @@ -285,7 +285,7 @@ Customizing your password will store it in your ~/.emacs file." | |||
| 285 | :safe 'stringp) | 285 | :safe 'stringp) |
| 286 | 286 | ||
| 287 | (defcustom sql-port 0 | 287 | (defcustom sql-port 0 |
| 288 | "Default port." | 288 | "Default port for connecting to a MySQL or Postgres server." |
| 289 | :version "24.1" | 289 | :version "24.1" |
| 290 | :type 'number | 290 | :type 'number |
| 291 | :group 'SQL | 291 | :group 'SQL |
| @@ -613,30 +613,22 @@ settings.") | |||
| 613 | '(:font-lock :sqli-program :sqli-options :sqli-login :statement)) | 613 | '(:font-lock :sqli-program :sqli-options :sqli-login :statement)) |
| 614 | 614 | ||
| 615 | (defcustom sql-connection-alist nil | 615 | (defcustom sql-connection-alist nil |
| 616 | "An alist of connection parameters for interacting with a SQL | 616 | "An alist of connection parameters for interacting with a SQL product. |
| 617 | product. | ||
| 618 | |||
| 619 | Each element of the alist is as follows: | 617 | Each element of the alist is as follows: |
| 620 | 618 | ||
| 621 | \(CONNECTION \(SQL-VARIABLE VALUE) ...) | 619 | \(CONNECTION \(SQL-VARIABLE VALUE) ...) |
| 622 | 620 | ||
| 623 | Where CONNECTION is a symbol identifying the connection, SQL-VARIABLE | 621 | Where CONNECTION is a symbol identifying the connection, SQL-VARIABLE |
| 624 | is the symbol name of a SQL mode variable, and VALUE is the value to | 622 | is the symbol name of a SQL mode variable, and VALUE is the value to |
| 625 | be assigned to the variable. | 623 | be assigned to the variable. The most common SQL-VARIABLE settings |
| 626 | 624 | associated with a connection are: `sql-product', `sql-user', | |
| 627 | The most common SQL-VARIABLE settings associated with a connection | 625 | `sql-password', `sql-port', `sql-server', and `sql-database'. |
| 628 | are: | ||
| 629 | |||
| 630 | `sql-product' | ||
| 631 | `sql-user' | ||
| 632 | `sql-password' | ||
| 633 | `sql-port' | ||
| 634 | `sql-server' | ||
| 635 | `sql-database' | ||
| 636 | 626 | ||
| 637 | If a SQL-VARIABLE is part of the connection, it will not be | 627 | If a SQL-VARIABLE is part of the connection, it will not be |
| 638 | prompted for during login." | 628 | prompted for during login. The command `sql-connect' starts a |
| 639 | 629 | predefined SQLi session using the parameters from this list. | |
| 630 | Connections defined here appear in the submenu SQL->Start... for | ||
| 631 | making new SQLi sessions." | ||
| 640 | :type `(alist :key-type (string :tag "Connection") | 632 | :type `(alist :key-type (string :tag "Connection") |
| 641 | :value-type | 633 | :value-type |
| 642 | (set | 634 | (set |
| @@ -3647,7 +3639,9 @@ The list is maintained in SQL interactive buffers.") | |||
| 3647 | (read-from-minibuffer prompt tname)))) | 3639 | (read-from-minibuffer prompt tname)))) |
| 3648 | 3640 | ||
| 3649 | (defun sql-list-all (&optional enhanced) | 3641 | (defun sql-list-all (&optional enhanced) |
| 3650 | "List all database objects." | 3642 | "List all database objects. |
| 3643 | With optional prefix argument ENHANCED, displays additional | ||
| 3644 | details or extends the listing to include other schemas objects." | ||
| 3651 | (interactive "P") | 3645 | (interactive "P") |
| 3652 | (let ((sqlbuf (sql-find-sqli-buffer))) | 3646 | (let ((sqlbuf (sql-find-sqli-buffer))) |
| 3653 | (unless sqlbuf | 3647 | (unless sqlbuf |
| @@ -3659,7 +3653,9 @@ The list is maintained in SQL interactive buffers.") | |||
| 3659 | (set (make-local-variable 'sql-buffer) sqlbuf)))) | 3653 | (set (make-local-variable 'sql-buffer) sqlbuf)))) |
| 3660 | 3654 | ||
| 3661 | (defun sql-list-table (name &optional enhanced) | 3655 | (defun sql-list-table (name &optional enhanced) |
| 3662 | "List the details of a database table. " | 3656 | "List the details of a database table named NAME. |
| 3657 | Displays the columns in the relation. With optional prefix argument | ||
| 3658 | ENHANCED, displays additional details about each column." | ||
| 3663 | (interactive | 3659 | (interactive |
| 3664 | (list (sql-read-table-name "Table name: ") | 3660 | (list (sql-read-table-name "Table name: ") |
| 3665 | current-prefix-arg)) | 3661 | current-prefix-arg)) |