JWorld@TW the best professional Java site in Taiwan
      註冊 | 登入 | 全文檢索 | 排行榜  

» JWorld@TW » Languages on JVM » JRuby  

按列印兼容模式列印這個話題 列印話題    把這個話題寄給朋友 寄給朋友    訂閱主題
reply to topicthreaded modego to previous topicgo to next topic
本主題所含的標籤
無標籤
作者 Ruby1.86安裝的資料庫
liang1022





發文: 35
積分: 0
於 2008-03-05 15:42 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
請問是否預設使用SQLLite
我每次建一個專案 rails xxx 它的database.yml
都是寫sqllite
要如何修改預設為MySQL呢


reply to postreply to post
lilu-elevator電梯
作者 Re:Ruby1.86安裝的資料庫 [Re:liang1022]
koji

秒速5センチメートル

站長

發文: 8415
積分: 19
於 2008-03-05 16:02 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
你是要問rails吧?
rails2.0.2之後我記得都變成sqlite
要改掉就自己手動改一下囉

不然就是產生時打
rails -d mysql app名稱 應該就可以勒?

koji


reply to postreply to post
JCConf Taiwan 2015 開始售票了!!
Facebook上的TWJUG社團,歡迎加入
作者 Re:Ruby1.86安裝的資料庫 [Re:koji]
liang1022





發文: 35
積分: 0
於 2008-03-05 20:48 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
koji wrote:
你是要問rails吧?
rails2.0.2之後我記得都變成sqlite
要改掉就自己手動改一下囉

不然就是產生時打
rails -d mysql app名稱 應該就可以勒?

koji


如果有帳號 密碼
要怎麼下參數呢??


reply to postreply to post
lilu-elevator電梯
作者 Re:Ruby1.86安裝的資料庫 [Re:liang1022]
koji

秒速5センチメートル

站長

發文: 8415
積分: 19
於 2008-03-05 22:44 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
那你應該產生後去database.yml 修改帳號密碼
他只是幫你產生一些東西
此時不會去連資料庫

koji


reply to postreply to post
JCConf Taiwan 2015 開始售票了!!
Facebook上的TWJUG社團,歡迎加入
作者 Re:Ruby1.86安裝的資料庫 [Re:liang1022]
liang1022





發文: 35
積分: 0
於 2008-03-06 20:28 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
謝謝啦

reply to postreply to post
lilu-elevator電梯
作者 Rails2.0应用生成default连接数据库改为mysql的办法: [Re:liang1022]
wangqidong





發文: 1
積分: 1
於 2008-03-07 09:19 user profilesend a private message to userreply to postreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
把Rails2.0应用生成default连接数据库改为mysql的办法:
windowsxp Dir: \ruby\lib\ruby\gems\1.8\gems\rails-2.0.2\lib\rails_generator\generators\applications\app
ubuntu Dir: /usr/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/rails_generator/generators/applications/app
  File: app_generator.rb
  Line11: default_options :db => (ENV["RAILS_DEFAULT_DATABASE"] || "sqlite3"),
Change to: default_options :db => (ENV["RAILS_DEFAULT_DATABASE"] || "mysql")  


reply to postreply to post
» JWorld@TW »  Languages on JVM » JRuby

reply to topicthreaded modego to previous topicgo to next topic
  已讀文章
  新的文章
  被刪除的文章
Jump to the top of page

JWorld@TW 本站商標資訊

Powered by Powerful JuteForum® Version Jute 1.5.8