On 9/22/2014 10:17 PM, stagirus wrote:
> Your above response almost gave a hope. But not too long.
> All DDLs are going to the public schema. I get the errors as follows:
>
> Error executing SQL CREATE TABLE public.databas...
> Caused by: org.postgresql.util.PSQLException: ERROR: schema "public" does
> not exist
huh. works in SQL.
$ psql
psql (9.3.5)
Type "help" for help.
postgres=# create database test;
CREATE DATABASE
postgres=# \c test
You are now connected to database "test" as user "postgres".
test=# create schema myschema;
CREATE SCHEMA
test=# set search_path to myschema;
SET
test=# drop schema public;
DROP SCHEMA
test=# create table stuff (id serial primary key, val text);
CREATE TABLE
test=# \d
List of relations
Schema | Name | Type | Owner
----------+--------------+----------+----------
myschema | stuff | table | postgres
myschema | stuff_id_seq | sequence | postgres
(2 rows)
test=#
--
john r pierce 37N 122W
somewhere on the middle of the left coast