emacs-wiki-discuss
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[emacs-wiki-discuss] Re: Before I start on the learning curve, is planne


From: Paul Lussier
Subject: [emacs-wiki-discuss] Re: Before I start on the learning curve, is planner mode for me?
Date: Sun, 26 Mar 2006 22:25:40 -0500
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux)

Oursoye <address@hidden> writes:

> Le 22-03-2006, Paul Lussier <address@hidden> a écrit :
>>  - database access (emacs has a great interface to
>>  postgres and MySql, etc.) 

Please don't interpret this a gui type of database widget, or modeling
software.  It's really not much more than you standard mysql or psql
client wrapped up in a terminal buffer.  But, since your inside emacs,
life is just easier, allowing you do easily cut'n'paste from database
buffers into things like e-mail, muse/planner, etc.

As an example, I have a small 'mypostgres.el' file I've been using
lately for connecting to a couple of different databases while I
develop some apps that will use the database.  It's simply does this:

    (setq sql-postgres-program "/usr/local/pgsql/bin/psql")
    (split-window-vertically)
    (setq sql-user "pll"
          sql-database "users")
    (sql-connect-postgres)
    (rename-buffer "*users*")
    (switch-to-buffer "*users*")

    (setq sql-database "hosts")
    (sql-connect-postgres)
    (rename-buffer "*hosts*")
    (switch-to-buffer-other-window "*hosts*")

Which gets me 2 windows, top and bottom, each of which is connected to
a different database, one names 'users', the other named 'hosts'.

I hope that helps some.
-- 

Seeya,
Paul





reply via email to

[Prev in Thread] Current Thread [Next in Thread]