From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Michael Mauger Newsgroups: gmane.emacs.bugs Subject: bug#7664: sql.el: In interactive sql- command, Add C-u to set connection port Date: Tue, 21 Dec 2010 19:04:30 -0800 (PST) Message-ID: <729725.45346.qm@web62507.mail.re1.yahoo.com> References: <87ipys2tcd.fsf@picasso.cante.net> <87y67jtxur.fsf@stupidchicken.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="0-986543547-1292987070=:45346" X-Trace: dough.gmane.org 1292988931 26381 80.91.229.12 (22 Dec 2010 03:35:31 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 22 Dec 2010 03:35:31 +0000 (UTC) Cc: Jari Aalto , 7664@debbugs.gnu.org To: Chong Yidong Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Dec 22 04:35:26 2010 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PVFU4-0006Bu-M8 for geb-bug-gnu-emacs@m.gmane.org; Wed, 22 Dec 2010 04:35:24 +0100 Original-Received: from localhost ([127.0.0.1]:58666 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PVFI8-0002mq-AO for geb-bug-gnu-emacs@m.gmane.org; Tue, 21 Dec 2010 22:23:04 -0500 Original-Received: from [140.186.70.92] (port=33197 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PVFI3-0002mi-KG for bug-gnu-emacs@gnu.org; Tue, 21 Dec 2010 22:23:01 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PVFI2-0001tH-6m for bug-gnu-emacs@gnu.org; Tue, 21 Dec 2010 22:22:59 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:51645) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PVFI2-0001tC-4r for bug-gnu-emacs@gnu.org; Tue, 21 Dec 2010 22:22:58 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1PVEtu-0003Oc-Fo; Tue, 21 Dec 2010 21:58:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Michael Mauger Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 22 Dec 2010 02:58:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 7664 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 7664-submit@debbugs.gnu.org id=B7664.129298667813042 (code B ref 7664); Wed, 22 Dec 2010 02:58:02 +0000 Original-Received: (at 7664) by debbugs.gnu.org; 22 Dec 2010 02:57:58 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PVEtq-0003OJ-GT for submit@debbugs.gnu.org; Tue, 21 Dec 2010 21:57:58 -0500 Original-Received: from web62507.mail.re1.yahoo.com ([69.147.75.99]) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1PVEtp-0003O6-IA for 7664@debbugs.gnu.org; Tue, 21 Dec 2010 21:57:57 -0500 Original-Received: (qmail 45364 invoked by uid 60001); 22 Dec 2010 03:04:30 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1292987070; bh=/gQLNaYjZ3Tvs/8RUvtAJ+WBbaiXaMAZ8fH5AdM3itA=; h=Message-ID:X-YMail-OSG:Received:X-Mailer:References:Date:From:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type; b=6UJx9BUva1UvCHiiq4bPrXuw9QSoIHjwWqEPhqYAgi5HWNU0kCa3J4hJnBzDDazmCAwGHIhuosUyjGcSyRnBZgyQMNhE9Frtcje0WTZAIIEfWYWbrRYIJt5g0hZEhxYQ0HPDePHfE5rC2ySUoVHN1DHefUk/lQBL7ByUMplAjtE= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:X-YMail-OSG:Received:X-Mailer:References:Date:From:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type; b=Q9cfzfMTxZb8i8JPy5T8MKu/gynu1UetKRmy0wm0AapywWjvSq5tHsa3+6umMp9wYA8w3ExWZpo5BR24Ns26XLtF1OleImew5dUntMsIwwanpY47AJYeeygkQyAWGIQ4dhavwl9YsMhMKX5EtKXkvPo7oUxYiYm/IGu3qKySrPA=; X-YMail-OSG: Xd3GGkUVM1nywJ.q0ENrnDY.nEUqSecxKMqy2DZCpQ27a72 S9TBBk56Md.kQ02jfAB9o.abxKHkPwUJ0YyckyuN4HDMNtgvDImj9PWmxt3f dVD6avt6P6dUMs9yIFLQ_JohYR.EOrKpImpXhrYyYd72kRJVksKPxjQ_9F2N xHW506Ii8w.._vd66.YCM0T.yPVEC2zQ4NqQMvByJuy0RQLexcbKTsUvwBI2 3t_AWvJGTx0YGR59feJnSvyx1Mtq8dUVOKcahBBlEcS_3FzuSwb6mBBuKI_Z zNYzioETxsmKqyVb8ljFBWDd1rZ2eKMJqk3vJMcDMl_hfCDhIPofd3zMqUeZ 1QuHaFdEPJ7FIx8W4wVwswTBML5qY023Byo1U8RfOw_iENC62PbTHNjRHl6w OkY43Il5CivnrC0IrL6IvZlIWXDKMKg-- Original-Received: from [98.216.52.54] by web62507.mail.re1.yahoo.com via HTTP; Tue, 21 Dec 2010 19:04:30 PST X-Mailer: YahooMailRC/553 YahooMailWebService/0.8.107.285259 In-Reply-To: <87y67jtxur.fsf@stupidchicken.com> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Tue, 21 Dec 2010 21:58:02 -0500 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:42726 Archived-At: --0-986543547-1292987070=:45346 Content-Type: text/plain; charset=us-ascii In Emacs 24, SQL.el supports the port login parameter. By customizing `sql-mysql-login-params' to include the atom `port' the port will be prompted for during login. If you don't specify a value, it will not be specified when you connect so it will use the default. You can also set a default value for port by customizing `sql-port'. (setq sql-mysql-login-params '(user password server port database)) Both MySQL and Postgres support the use of port during login. ________________________________ From: Chong Yidong To: Michael R. Mauger Cc: Jari Aalto ; 7664@debbugs.gnu.org Sent: Tue, December 21, 2010 1:59:40 AM Subject: Re: bug#7664: sql.el: In interactive sql- command, Add C-u to set connection port Jari Aalto writes: > In production environments the database servers run in multiple ports, > like > > M-x sql-mysql > > It would be nice to be able to specify PORT number during interactive > call, like: > > C-u M-x sql-mysql > ... > Port: ..... Michael, could you take a look at this wishlist item? Currently, sql-mysql already uses a prefix argument to output into a new buffer. If you decide this suggestion is worth implementing, there are a couple of possibilities: (i) add another interactive command that prompts for a port number, or (ii) change the interactive spec so that a prefix arg prompts the user about whether to use a new buffer and what port to use. I don't use sql.el, so I don't know which makes more sense. --0-986543547-1292987070=:45346 Content-Type: text/html; charset=us-ascii
In Emacs 24, SQL.el supports the port login parameter. 

By customizing `sql-mysql-login-params'  to include the atom `port' the port will be prompted for during login.  If you don't specify a value, it will not be specified when you connect so it will use the default.   You can also set a default value for port by customizing `sql-port'.

   (setq sql-mysql-login-params '(user password server port database))

Both MySQL and Postgres support the use of port during login. 



From: Chong Yidong <cyd@stupidchicken.com>
To: Michael R. Mauger <mmaug@yahoo.com>
Cc: Jari Aalto <jari.aalto@cante.net>; 7664@debbugs.gnu.org
Sent: Tue, December 21, 2010 1:59:40 AM
Subject: Re: bug#7664: sql.el: In interactive sql-<product> command, Add C-u to set connection port

Jari Aalto <jari.aalto@cante.net> writes:

> In production environments the database servers run in multiple ports,
> like
>
>    M-x sql-mysql
>
> It would be nice to be able to specify PORT number during interactive
> call, like:
>
>    C-u M-x sql-mysql
>    ...
>    Port: .....

Michael, could you take a look at this wishlist item?  Currently,
sql-mysql already uses a prefix argument to output into a new buffer.
If you decide this suggestion is worth implementing, there are a couple
of possibilities: (i) add another interactive command that prompts for a
port number, or (ii) change the interactive spec so that a prefix arg
prompts the user about whether to use a new buffer and what port to use.
I don't use sql.el, so I don't know which makes more sense.

--0-986543547-1292987070=:45346--