3,765
回編集
差分
→通帳テーブル
update_heroku=# ALTER TABLE bankbooks RENAME COLUMN jiin_id TO note_id;
ALTER TABLE
ダンプ リストア
<nowiki>jq@MacBook-Pro tep5 % pg_dump --username=jq --table bankbooks update_heroku > ../new_bankbooks.sql
jq@MacBook-Pro tep5 % psql --username=jq tep5_development < ../new_bankbooks.sql
SET
SET
SET
SET
SET
set_config
------------
(1 row)
SET
SET
SET
SET
SET
SET
ERROR: relation "bankbooks" already exists
ALTER TABLE
ERROR: relation "bankbooks_id_seq" already exists
ALTER TABLE
ALTER SEQUENCE
ALTER TABLE
COPY 36
setval
--------
68
(1 row)
ERROR: multiple primary keys for table "bankbooks" are not allowed
CREATE INDEX
ERROR: relation "index_bankbooks_on_user_id" already exists
CREATE INDEX
ERROR: relation "public.jiins" does not exist</nowiki>
== UUIDを有効にする ==