• 締切済み

createuser

Postgresql8で、createuserコマンドを使用すると、 Shall the new role be a superuser? (y/n) Shall the new role be allowed to create databases? (y/n) Shall the new role be allowed to create more new roles? (y/n) 以前のOracleやPostgreSQL7以前では、user追加のメッセージが返ってきたと思います。 何故、新しいuserを作ろうとすると、新しロールを作ることになるのですか?

みんなの回答

  • TA-HT81S
  • ベストアンサー率39% (72/184)
回答No.1

PostgreSQL8から、ロールという概念が追加されたのですが、その実はユーザの追加と同じです。 ですから、 Shall the new role be a superuser? (y/n) については、「追加するロール(ユーザ)をpostgres同等にするか?」 ということで、 Shall the new role be allowed to create databases? (y/n) Shall the new role be allowed to create more new roles? (y/n) については、それぞれ、 「あたらしいDBを作る権限を与えるか?」 「新しいロール(ユーザ)を作る権限を与えるか?」 ということです。 ロールという言葉を気にしないでも良いようです。

全文を見る
すると、全ての回答が全文表示されます。

関連するQ&A

  • 外部キーを持つテーブルを作成しようとするとエラーがでます

    XAMPPバージョン1.5.4 MySQLバージョン4.1.16 という環境で、my.cnfでInnoDBを使えるように設定しています。 そして CREATE TABLE admin_roles (id BIGINT UNSIGNED AUTO_INCREMENT PRIMARY KEY, name VARCHAR(12) NOT NULL) ENGINE = InnoDB; という非参照列idを持つadmin_rolesテーブルを作り(成功し)、さらに role_idを外部キーとしてadmin_user_roleテーブルを作成しようとすると、 Error Number: 1005 Can't create table '.\test\admin_user_role.frm' (errno: 150) CREATE TABLE admin_user_role (userid VARCHAR(12) NOT NULL, role_id BIGINT DEFAULT 0, FOREIGN KEY (role_id) REFERENCES admin_roles(id) ON DELETE CASCADE) ENGINE = InnoDB; というエラーが出てしまいます・・・ admin_user_roleの記述のどこが間違っているのでしょうか?

    • ベストアンサー
    • MySQL
  • 挿入ができない

    MySQLバージョン4.1.16を使用しています。 「user_role」テーブルを 「users」テーブルのuser_idカラムと「roles」テーブルのrole_seqカラムを外部キーとして作成します。 そして「user_role」テーブルにuser_id「aaaa」とrole_seq「1」をINSERTしようとしたのですが、 以下のようなエラーが出てしまいます。 Cannot add or update a child row: a foreign key constraint fails (`test/user_role`, CONSTRAINT `user_role_ibfk_2` FOREIGN KEY (`user_id`) REFERENCES `users` (`user_id`) ON DELETE CASCADE) INSERT INTO user_role (user_id, role_seq) VALUES ('aaaa', 1) どこらへんが間違っているのでしょうか? 以下の手順でテーブルを作成しました。 CREATE TABLE users (user_id VARCHAR(16) NOT NULL, password VARCHAR(32) NOT NULL, regist_date DATETIME NOT NULL, PRIMARY KEY (user_id)) ENGINE = InnoDB CREATE TABLE roles (role_seq BIGINT UNSIGNED AUTO_INCREMENT, name VARCHAR(32) NOT NULL, PRIMARY KEY (role_seq)) ENGINE = InnoDB CREATE TABLE user_role (role_seq BIGINT UNSIGNED, user_id VARCHAR(16) NOT NULL, FOREIGN KEY (role_seq) REFERENCES roles(role_seq) ON DELETE CASCADE, FOREIGN KEY (user_id) REFERENCES users(user_id) ON DELETE CASCADE) ENGINE = InnoDB

    • ベストアンサー
    • MySQL
  • 規約の英文を添削お願いします。4行です。

    規約の英文を添削お願いします。4行です。 以下、審査の条件を私がなんとか英語にしたものです。(書いてないのですが、主語になるのは、審査対象となる研究テーマのようなものです。) ・Shall be in line with the development of science, not pursuing the interests of individuals and corporations. ・Shall be judged difficult to be achieved with the ordinal method. ・Priority shall be placed on domestic organization considering the way tax money is used. ・Shall lead to create new industries or products. However, facilities shall not be provided for productive activity except trial level.

  • 英文和訳のお願いです。技術文書です。

    Procedures shall be developed to ensure that radioactive material received at the facility is appropriately characterized and acceptable before it is allowed to be stored or used within the facility.

  • 同一筺体にOracle 10g XE とOracle Clientを入れて動かしたい

    ■実現したいこと■ Oracle Database 10g Express Edition (Universal) Oracle Database 10g Express Client を同一筺体にインストールして、コマンドプロンプトからsqlplusを起動してDBを操作する ■行った事■ 「http://127.0.0.1:8080/apex/」の管理者画面からデータベース・ユーザー"HR"(サンプルユーザ)のアカウントステータスを 「ロック済」→「ロック解除済」にした。 ※HRユーザの権限は以下の通りです。 ユーザー権限 ロール:  CONNECT   ○ RESOURCE  ○ DBA     ○ 直接付与されたシステム権限: CREATE DATABASE LINK ○ CREATE MATERIALIZED VIEW× CREATE PROCEDURE    × CREATE PUBLIC SYNONYM × CREATE ROLE     × CREATE SEQUENCE     × CREATE SYNONYM     ○ CREATE TABLE × CREATE TRIGGER × CREATE TYPE × CREATE VIEW × ■環境■ Windows Vista SP1 上記のようなやってコマンドプロンプトから sqlpulsを起動して、ユーザID(HR)とパスワードを入力した所 「ORA-12560: TNS: プロトコル・アダプタ・エラーが発生しました」 というエラーが出てしまいました。 何か足りない操作があるんでしょうか。それとも元々同一筺体にて使用できないんでしょうか。 どなたかご教授下さい。 よろしくお願い致します。

  • SYSTEM表領域にインポートされてしまう

    TASC_DATA表領域にインポートしたいのだが、 CREATE USER で 間違ってますか? CREATE USER TASC_USER IDENTIFIED BY TASC_USER DEFAULT TABLESPACE TASC_DATA TEMPORARY TABLESPACE TASC_TEMP PROFILE DEFAULT / GRANT CONNECT TO TASC_USER / GRANT RESOURCE TO TASC_USER / GRANT CREATE ROLE TO TASC_USER / GRANT EXECUTE ANY PROCEDURE TO TASC_USER / GRANT UNLIMITED TABLESPACE TO TASC_USER /

  • どうやって作ればいいんですか?

    どうやって作ればいいんですか? サーバーでデータベースを作成します。      <PostgreSQLの場合>   $ createdb DB名   <MySQLの場合>   # mysqladmin create DB名   # mysql DB名   mysql> ALTER DATABASE DB名 DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci; 6. サーバーでデータベースユーザーを作成します。     <PostgreSQLの場合>   $ createuser DB接続ユーザー名    ⇒質問に対して「y」を入力してスーパーユーザー権限を与えてください。   $ createuser daemon    ⇒質問に対して全て「n」を入力してください。   $ createuser mailnull    ⇒質問に対して全て「n」を入力してください。   <MySQLの場合>   # mysql DB名   mysql> GRANT ALL PRIVILEGES ON *.* TO DB接続ユーザー名@DBホスト名 IDENTIFIED BY 'DB接続ユーザーパスワード' WITH GRANT OPTION;

  • アパートの賃貸リース契約がもうすぐ切れるのですが・・・(アメリカ)

    英語カテゴリと迷ったのですが、暮らしに密着した質問なので、こちらのカテゴリにしました。よろしくお願いします。 アメリカ在住です。昨年5月に現在のアパートに入居し、1年の賃貸リース契約を結びました。要するに「1年は自由に退去できない“しばり”」があったわけですが、一般的に、1年過ぎた後はどのような形になるのでしょうか? 新たに契約書を交わすのですか? 昨年契約を結ぶ時にも、そのことを大家さんに聞きましたが、「月払いに切り替えたいというケースが一番多いけど、まあそれはまたその時に。レントは今のままで据え置きになると思う」という程度の説明でした。 しかし、期限が迫っても大家さんからも特に何も話がないので、気になって契約書を丁寧に読み返してみました。お恥ずかしいのですが、こういった不動産契約の文面は読み慣れないため、ある程度意味は取れても細かいニュアンスに自信がなく、正直「分かった」とは言えない状態です。万一、リース期限をもって追い出されるようなことがあっては、泣くに泣けません・・・ こちらでの賃貸契約の慣例なども含めて、私の置かれた状況を解説していただけましたら有り難く存じます。 以下、契約書の抜粋です。 1. TERM This Agreement shall commence on 1st, June, 2008 ("Commencement Date") [check either A or B] [ ] A. Month-to-Month: This Agreement shall continue as a month-to-month tenancy. If at any time Tenant desires to terminate the tenancy, Tenant may do so by providing to Landlord written notice of intention to terminate. Such notice to terminate must be provided to Landlord at least 30 days prior to the desired date of termination of the tenancy. If at any time Landlord desires to terminate at least 30 days prior to the desired date of termination of the tenancy. Notices to terminate may be given on any calendar day, irrespective of Commencement Date. [*] B. Lease: This Agreement shall continue as a lease for term. The termination date shall be on 5/31/09 at 11:59 PM. Upon termination date, Tenant shall be required to vacate the Premises unless one of the following circumstances occur: (i) Landlord and Tenant formally extend this Agreement in writing or create and execute a new, witten, and signed agreement; (ii) local rent control law mandates extension of the tenancy; or (iii) Landlord willingliy accepts from Tenant new rent, a month-to-month tenancy shall be created. Either party may terminate this month-to-month tenancy by following the procedures specified in paragraph 1A. Rent shall continue at the rate specified in this Agreement, or as allowed by law. All other terms and conditions as outlined in this Agreement shall remain in full force and effect. リース契約ですので、Bのほうに*(チェック)が付いています。私は当初、(iii)の部分に着目して、「6月のレントをいつも通り支払った時点で、Aの月払いに自動的に移行するのだ」と考えていたのですが、よく読み返してみると、「Tenant shall be required to vacate the Premises unless ~」のところが、「特に何もなければ退去しなければならない」という意味にも取れ、とても不安になってしまいました。 長文すみません。どうぞよろしくお願い致します。今、とても引っ越しができる状況ではないので、追い出されることになったらどうしようかと、冷や汗をかいております・・・

  • 中途解約の場合のペナリティーは?

    以下の英文の契約書について、教えて下さい。 ワイキキの知人が契約しているコンドですが、 A- この契約を中途解約する場合、契約期間の残り期間の家賃を全額支払うことになるのでしょうか? B- 「2. TERM」の条項にある、「Thereafter」とは「 DECEMBER 1, 2010」以降を指すのでしょうか、 それとも、契約期間6カ月が過ぎた後のことを指すのでしょうか? STANDARD RENTAL AGREEMENT 1. COMMENCEMENT DATE. This Agreement shall commence on DECEMBER 1, 2010. 2. TERM. This Agreement shall be for a Six (6) month term. Thereafter, the Agreement shall be month to month tenancy. The Tenant may end the month to month tenancy by providing Landlord written notice of intention to terminate. Such notice to terminate must be provided to Landlord at least 30 days prior to the desired date of termination of the tenancy. If at any time Landlord desires to terminate the tenancy, Landlord may do so by providing to Tenant such written notice of intention to terminate at least 30 days prior to the desired date of termination of the tenancy. 17. TENANT’S HOLD OVER. If Tenant remains in possession of the Premises with the consent of Landlord after the natural expiration of this Agreement, a new tenancy from month-to-month shall be created between Landlord and Tenant which shall be subject to all the terms and conditions hereof except that rent shall be then be due and owing at $1600.00 per month

  • willと be going toの違いについてお答えお願いします。

    willと be going toの違いについてお答えお願いします。 英作文に挑戦の問題で、「僕の彼女は、彼と一緒にドライブに行くつもりだ」とあります。 答えはMy girlfriend will go for drive with him.ですが、 My girlfriend is going to go for drive with him.ではダメなのでしょうか? また、同じ英作文作成の問題で、 あなたのお父さんはN.Y.に今夜出発するつもりですか」とあり、 答えが「Will your father leave for N.Y. tonight?」となります。 この場合に、「Is your father going to go leave for N.Y. tonight?」と答えると間違いになりますか? 何故 be going toではダメなのか、どういう場合にbe going toになるのかがわかりません。 あと、「今夜」という単語がtonightとなっていますが、this eveningで代用は出来るでしょうか? 宜しくお願いします。