Create Schema functionality question

Поиск
Список
Период
Сортировка
От Seamus Thomas Carroll
Тема Create Schema functionality question
Дата
Msg-id Pine.LNX.4.44.0402231831320.1660-100000@ict715b
обсуждение исходный текст
Ответы Re: Create Schema functionality question  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general
Hi,

I am trying to create a schema where the schema name has been defined in
another table.  My sql looks like:
create schema (select agent_schema from agents.agents where agent_id =
(select(last_value) from agents.agents_seq));

The select statement works correctly on its own but when added to
"create schema" I get the following error:
ERROR:  syntax error at or near "(" at character 15

Is there any possible way to create a schema without having
to hard code the name?

Seamus


В списке pgsql-general по дате отправления:

Предыдущее
От: Sean Shanny
Дата:
Сообщение: Re: Found this in the server log on MAC OSX
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Found this in the server log on MAC OSX