Next: , Previous: CL-SQL, Up: Installation

3.8 CL-SQL Example

To set up a PostGres based back end, you should:

  1. Install postgres and make sure postmaster is running. Postgres may be installed on your system; you may be able to use a package manager to install it, or you can install it from the PostgresSQL site directly (
  2. Create a database called “test” and set its permissions to be reached by whatever connection specification you intend to use. The tests use:
              (defvar *testpg-path*
              '(:postgreql "localhost.localdomain" "test" "postgres" ""))

    which means that connections must be allowed to the database test, user “postgres”, no password, connected from the same machine “localhost.localdomain”. (This would be changed to something more secure in a real application.) Typically you edit the file : pg_hba.conf to enable various kinds of connections in postgres.

  3. Be sure to enable socket connection to postgres when you invoke the postmaster.
  4. Test that you can connect to the database with these credentials by running: psql -h -U postgres test before you attempt to connect with Elephant.

Furthermore, you must grant practically all creation/read/write privileges to the user postgres on this schema, so that it can construct the tables it needs.

Upon first opening a CL-SQL based store controller, the tables, indexes, sequences, and so on needed by the Elephant system will be created in the schema named “test” automatically.