我重命名錶軌重命名錶id_seq
rename_table :posts, :messages
但軌道產生posts_id_seq和posts.id修飾符:
db=# \d+ posts
Table "public.posts"
Column | Type | Modifiers | Storage | Description
id | integer | not null default nextval('posts_id_seq'::regclass) | plain |
Indexes:
"posts_pkey" PRIMARY KEY, btree (id)
如何糾正重命名錶?
紅寶石1.8.7
軌2.3
我編輯了問題 – Nar 2013-03-21 06:03:02