mungkin ini masalah encoding di koneksi aplikasi ke mysqlnya, set di database.yml mis.
development: adapter: mysql database: dev username: root password: socket: /tmp/mysql.sock encoding: UTF8 On Fri, 14 Sep 2007 10:44:32 +0700, Aditya Agustyana <[EMAIL PROTECTED]> wrote: > semua tabel di migration telah aku set menjadi UTF8 > > ex > > create_table(:items,:options => 'ENGINE=InnoDB DEFAULT > CHARSET=utf8') do |t| > t.column :name,:string > t.column :description,:text > t.column :price,:integer > t.column :shop_id,:integer > end > > ini akan membuat table items di database _development dengan opsi > engine memakai InnoDB dan charset=utf8 > > nah anehnya, setiap menjalankan rake:test, tabel2 yang ada di database > _test, charsetnya tidak berubah ke utf8 melainkan tetep > latin_swedish_ci (defaultnya mysql) > > hiks ini menjadi problem besar, karena ketika menjalankan rake:test, > test selalu fail, dengan pesan sbg berikut > > ActiveRecord::StatementInvalid: Mysql::Error: #HY000Illegal mix of > collations (latin1_swedish_ci,IMPLICIT) and > (utf8_general_ci,COERCIBLE) for operation '=': SELECT * FROM items > WHERE (items.title = > 'りんごとケダモノ' AND > items.shop_id = 1 AND > items.id <> 1) LIMIT 1 > > gmn yak cara mengatasi masalah ini ?, dr kemaren udah nyari2 tapi > solusinya blum dapet > > oh iya satu lagi,apakah betul ketika melakukan rake:test , rails akan > mengeksekusi rake db:test:clone juga ?, kalo iya ada yg tau gmn > caranya -nge override rake db:test:clone > > note : > rails versi 1.2.3 > ruby versi 1.8.6 > mysql versi 5.0.41 > > makasih sebelumnya > > > > > > > ID-Ruby > Berdiskusi dan belajar bersama Bahasa Pemrograman Ruby, termasuk segala > varian Ruby (JRuby, Rubinius, IronRuby, XRuby), dan program yang dibuat > dengan Ruby (Ruby on Rails, JRuby on Rails) > > http://news.gmane.org/gmane.comp.lang.ruby.region.indonesia > > Yahoo! Groups Links > > > -- Using Opera's revolutionary e-mail client: http://www.opera.com/mail/ ID-Ruby Berdiskusi dan belajar bersama Bahasa Pemrograman Ruby, termasuk segala varian Ruby (JRuby, Rubinius, IronRuby, XRuby), dan program yang dibuat dengan Ruby (Ruby on Rails, JRuby on Rails) <*> Kunjungi *arsip milis* id-ruby di http://groups.yahoo.com/group/id-ruby/messages http://www.mail-archive.com/[email protected]/ http://news.gmane.org/gmane.comp.lang.ruby.region.indonesia <*> *Baca peraturan id-ruby* sebelum posting http://tech.groups.yahoo.com/group/id-ruby/files/ <*> Ikutilah *Jajak Pendapat ID-Ruby* http://tech.groups.yahoo.com/group/id-ruby/polls <*> *Links ID-Ruby* http://tech.groups.yahoo.com/group/id-ruby/links <*> *Database ID-Ruby* http://tech.groups.yahoo.com/group/id-ruby/database <*> Kunjungi Situs Resmi Ruby Indonesia http://www.ruby-lang.org/id/ Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/id-ruby/ <*> Your email settings: Individual Email | Traditional <*> To change settings online go to: http://groups.yahoo.com/group/id-ruby/join (Yahoo! ID required) <*> To change settings via email: mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/

