0
我在運行rails應用程序和postgres作爲後端時出現以下uuid錯誤。有人可以幫我解決哪些依賴需要。在運行rake遷移時遇到postgres錯誤
[[email protected] webapp]# rake db:migrate
(in /root/mysite/webapp)
== CreateContributors: migrating =============================================
-- create_table(:contributors, {:id=>false})
-> 0.0121s
-- execute("alter table contributors add primary key (id)")
NOTICE: ALTER TABLE/ADD PRIMARY KEY will create implicit index "contributors_pkey" for table "contributors"
-> 0.0797s
-- execute("alter table contributors alter column id set default uuid_generate_v1()::varchar")
rake aborted!
An error has occurred, this and all later migrations canceled:
PGError: ERROR: function uuid_generate_v1() does not exist
HINT: No function matches the given name and argument types. You might need to add explicit type casts.
: alter table contributors alter column id set default uuid_generate_v1()::varchar
感謝現在的工作其實路徑是有人在的pgsql/contrib請一個問題,我一直在尋找在Postgres的文件夾 – 2012-02-20 07:17:10
在Ubuntu這個文件的目錄似乎是: 在/ usr /共享/ PostgreSQL的/ [Postgres的版本]/延期 – MissingHandle 2013-10-03 00:02:59