我想部署我的rails應用程序與heroku。我跑heroku run rake db:migrate
,這工作得很好。然後我試着運行heroku run rake db:seed
,我得到了這個錯誤:value too long for type character varying(255)
。如何看到什麼屬性給我這個錯誤:價值太長的類型字符變化(255)
我翻遍了我的代碼,我很確定所有的字符串屬性都少於255個字符。我如何看到哪個屬性給我錯誤?
~/collegeanswerz >> heroku run rake db:migrate
Running `rake db:migrate` attached to terminal... up, run.6374
DEPRECATION WARNING: You have Rails 2.3-style plugins in vendor/plugins! Support for these plugins will be removed in Rails 4.0. Move them out and bundle them in your Gemfile, or fold them in to your app as lib/myplugin/* and config/initializers/myplugin.rb. See the release notes for more on this: http://weblog.rubyonrails.org/2012/1/4/rails-3-2-0-rc2-has-been-released. (called from <top (required)> at /app/Rakefile:7)
DEPRECATION WARNING: You have Rails 2.3-style plugins in vendor/plugins! Support for these plugins will be removed in Rails 4.0. Move them out and bundle them in your Gemfile, or fold them in to your app as lib/myplugin/* and config/initializers/myplugin.rb. See the release notes for more on this: http://weblog.rubyonrails.org/2012/1/4/rails-3-2-0-rc2-has-been-released. (called from <top (required)> at /app/Rakefile:7)
Connecting to database specified by DATABASE_URL
Migrating to CreateColleges (20130529230046)
Migrating to AddDetailsToCollege (20130529231454)
Migrating to AddMoredetailsToCollege (20130530024157)
Migrating to AddAaaToCollege (20130530140803)
Migrating to AddBbbToCollege (20130530141312)
Migrating to AddCccToCollege (20130530142345)
Migrating to AddDddToCollege (20130530142537)
Migrating to AddNameToCollege (20130530145608)
Migrating to AddUrlToColleges (20130607205230)
Migrating to DeleteActFromColleges (20130608162648)
Migrating to AddActToColleges (20130608162707)
Migrating to RemoveActFromColleges (20130608162808)
Migrating to AddCostToColleges (20130608193301)
Migrating to AddLinksToColleges (20130608232148)
Migrating to AddScholToColleges (20130608232522)
Migrating to AddMapToColleges (20130609222024)
Migrating to AddHousingToColleges (20130609235838)
Migrating to AddFwToColleges (20130610003429)
Migrating to AddDormsToColleges (20130610145106)
Migrating to AddMajorsooToColleges (20130610154704)
Migrating to RemoveMajorsooFromColleges (20130610155336)
Migrating to AddMajorsoooToColleges (20130610155625)
Migrating to AddDormurlsToColleges (20130613023113)
~/collegeanswerz >> heroku run rake db:seed
Running `rake db:seed` attached to terminal... up, run.6256
DEPRECATION WARNING: You have Rails 2.3-style plugins in vendor/plugins! Support for these plugins will be removed in Rails 4.0. Move them out and bundle them in your Gemfile, or fold them in to your app as lib/myplugin/* and config/initializers/myplugin.rb. See the release notes for more on this: http://weblog.rubyonrails.org/2012/1/4/rails-3-2-0-rc2-has-been-released. (called from <top (required)> at /app/Rakefile:7)
DEPRECATION WARNING: You have Rails 2.3-style plugins in vendor/plugins! Support for these plugins will be removed in Rails 4.0. Move them out and bundle them in your Gemfile, or fold them in to your app as lib/myplugin/* and config/initializers/myplugin.rb. See the release notes for more on this: http://weblog.rubyonrails.org/2012/1/4/rails-3-2-0-rc2-has-been-released. (called from <top (required)> at /app/Rakefile:7)
Connecting to database specified by DATABASE_URL
rake aborted!
PGError: ERROR: value too long for type character varying(255)
: UPDATE "colleges" SET "url" = 'university-of-pittsburgh', "public" = 'Public', "years" = '4-year', "category" = 'National University', "calendar" = 'Semester', "location" = 'Pittsburgh, PA', "setting" = 'Large City (250-500k)', "retention" = 90, "graduation4" = 57, "graduation6" = 79, "degrees" = 'Certificate, Bachelors, Masters, Doctoral', "rotc" = 'Air Force, Army, Navy', "sat_submit" = 89, "act_submit" = 41, "sat_math_25" = 600, "sat_math_75" = 690, "sat_reading_25" = 570, "sat_reading_75" = 690, "sat_writing_25" = 560, "sat_writing_75" = 660, "sat_composite_25" = 1130, "sat_composite_75" = 1320, "act_math_25" = 25, "act_math_75" = 30, "act_reading_25" = 25, "act_reading_75" = 31, "act_writing_25" = 7, "act_writing_75" = 9, "act_composite_25" = 25, "act_composite_75" = 30, "acceptance_rate" = 58, "enrolled" = 32, "gpa375" = 71, "gpa35" = 15, "gpa325" = 8, "gpa3" = 4, "gpa25" = 2, "high_school_tenth" = 54, "high_school_quarter" = 86, "high_school_half" = 99, "sat_math_700" = 25, "sat_math_600" = 53, "sat_math_500" = 21, "sat_math_400" = 1, "sat_math_300" = 0, "sat_reading_700" = 24, "sat_reading_600" = 42, "sat_reading_500" = 32, "sat_reading_400" = 2, "sat_reading_300" = 0, "sat_writing_700" = 14, "sat_writing_600" = 45, "sat_writing_500" = 37, "sat_writing_400" = 4, "sat_writing_300" = 0, "act_composite_30" = 33, "act_composite_24" = 58, "act_composite_18" = 8, "act_composite_12" = 1, "act_math_30" = 40, "act_math_24" = 46, "act_math_18" = 13, "act_math_12" = 1, "act_reading_30" = 0, "act_reading_24" = 0, "act_reading_18" = 0, "act_reading_12" = 0, "very_important" = 'Academic GPA|Rigor of secondary school record|Standardized Test Scores', "considered" = 'Application Essay|Character/Personal Qualities|Class Rank|Extracurricular Activities|First Generation College Student|Geographical Residence|Level of Applicant''s Interest|Racial/Ethnic Status|Recommendations|State Residency|Talent/Ability|Volunteer Work|Work Experience', "student_faculty" = '14 to 1', "class_20" = 42, "class_49" = 39, "class_50" = 18, "majors" = 'business/marketing: 15%|social sciences: 14%|health professions: 11%|english: 10%|engineering: 9%|psychology: 8%|biology: 7%|history: 5%', "law" = 3, "business" = 1, "medical" = 4, "other_grad" = 28, "us_news_ranking" = 58, "top_25_grad" = 'Physical Therapy (3)|Speech-Language Pathology (8)|Library and Information Studies (10)|Social Work (11)|Medicine (15)|Education (24)', "requirements" = 'http://www.asundergrad.pitt.edu/requirements/gened.html', "majors_offered_link" = 'http://www.pitt.edu/academics/undergraduate', "ap_credit" = 'http://www.oafa.pitt.edu/pdf/CreditAPIBExam.pdf', "enrollment" = 18427, "graduate_enrollment" = 10339, "in_state" = 68, "out_of_state" = 32, "male" = 49, "female" = 51, "ethnicity" = 'white: 77%|hispanic/latino: 2%|asian: 8%|black: 5%|2 or more races: 3%|non-resident aliens: 3%|other: 2%', "frats" = 12, "sororities" = 10, "on_campus" = 45, "freshman_on_campus" = 97, "in_state_tuition" = 16590, "out_of_state_tuition" = 26280, "room_and_board" = 9870, "with_need_got_aid" = 68, "got_need_fully_met" = 7, "percent_need_met" = 59, "scholarships" = 41, "loans" = 59, "cost_30" = 17326, "cost_48" = 19950, "cost_75" = 23636, "cost_110" = 26410, "cost_111" = 26985, "scholarships_link" = 'http://www.oafa.pitt.edu/universityschlrs.aspx', "map" = '<iframe width="425" height="350" frameborder="0" scrolling="no" marginheight="0" marginwidth="0" src="https://maps.google.com/maps?f=q&source=s_q&hl=en&geocode=&q=university+of+pittsburgh&aq=&sll=40.444261,-79.970448&sspn=0.142165,0.251656&ie=UTF8&hq=university+of+pittsburgh&t=m&ll=40.443486,-79.958245&spn=0.010798,0.021038&output=embed"></iframe><br /><small><a href="https://maps.google.com/maps?f=q&source=embed&hl=en&geocode=&q=university+of+pittsburgh&aq=&sll=40.431368,-79.9805&sspn=0.142165,0.251656&ie=UTF8&hq=university+of+pittsburgh&t=m&ll=40.443486,-79.958245&spn=0.010798,0.021038" style="color:#0000FF;text-align:left">View Larger Map</a></small>', "street_view" = '<iframe width="425" height="350" frameborder="0" scrolling="no" marginheight="0" marginwidth="0" src="https://maps.google.com/maps?f=q&source=embed&hl=en&geocode=&q=University+of+Pittsburgh,+4200+Fifth+Ave,+Pittsburgh,+PA&aq=0&oq=uni&sll=40.444261,-79.970448&sspn=0.142165,0.251656&ie=UTF8&hq=University+of+Pittsburgh,+4200+Fifth+Ave,+Pittsburgh,+PA&ll=40.443486,-79.958245&spn=0.010798,0.021038&t=m&layer=c&cbll=40.441775,-79.956671&panoid=BgWQKMiSI1fpwP7JUF16Vg&cbp=12,45.25,,0,-3.34&output=svembed"></iframe><br /><small><a href="https://maps.google.com/maps?f=q&source=embed&hl=en&geocode=&q=University+of+Pittsburgh,+4200+Fifth+Ave,+Pittsburgh,+PA&aq=0&oq=uni&sll=40.431368,-79.9805&sspn=0.142165,0.251656&ie=UTF8&hq=University+of+Pittsburgh,+4200+Fifth+Ave,+Pittsburgh,+PA&ll=40.443486,-79.958245&spn=0.010798,0.021038&t=m&layer=c&cbll=40.441775,-79.956671&panoid=BgWQKMiSI1fpwP7JUF16Vg&cbp=12,45.25,,0,-3.34" style="color:#0000FF;text-align:left">View Larger Map</a></small>', "housing" = '<iframe src="http://www.tour.pitt.edu/tour-categories/residence-halls" scrolling="no" height="820" width="900"></iframe>', "food" = '<div style="overflow: hidden; max-width: 1000px;"><iframe scrolling="no" src="http://www.pc.pitt.edu/dining/menus.php" style="margin-left: 0; height: 2000px; margin-top: -370px; margin-bottom: -375px; width: 750px;"></iframe></div>', "weather" = '<div style="overflow: hidden; max-width: 500px;"><iframe scrolling="no" src="http://www.weather.com/weather/wxclimatology/monthly/graph/USPA1290" style="margin-left: -40px; height: 1570px; margin-top: -490px; width: 500px;"></iframe></div>', "dorms" = 'Towers (fr.)|Sutherland (fr.)|Lothrop (fr.)|Nordenberg (fr.)|Holland (fr.)|Forbes (fr.; honors)|McCormick|Brackenridge|Amos|Bruce|Panther|Pennsylvania|Ruskin|Bouquet Gardens|Oakwood Apartments|Centre-Plaza Apartments|Forbes-Craig Apartments (honors)', "dorm_urls" = 'towers|sutherland|lothrop|nordenberg|holland|forbes|mccormick|brackenridge|amos|bruce|panther|pennsylvania|ruskin|bouquet-gardens|oakwood-apartments|centre-plaza-apartments|forbes-craig-apartments', "science_majors" = 'Actuarial Mathematics|Applied Mathematics|Bioinformatics|Biological Sciences|Chemistry|Computer Science|Ecology and Evolution|Environmental Geology|Environmental Studies|Geology|History and Philosophy of Science|Linguistics|Mathematics|Mathematics-Economics|Mathematics-Philosophy|Microbiology|Molecular Biology|Natural Sciences Area|Neuroscience|Physics|Physics and Astronomy|Scientific Computing|Statistics', "social_science_majors" = 'Economics|Economics–Statistics|History|Political Science|Politics-Philosophy|Psychology|Sociology|Urban Studies', "humanities_majors" = 'Africana Studies|Africana Studies–English|Anthropology|Chinese|Classics|English Literature|English Writing|Film Studies|French|German|History of Art & Architecture|Humanities Area|Italian|Italian Studies|Japanese|Liberal Studies|Music|Philosophy|Religious Studies|Russian|Slavic Studies|Spanish|Studio Arts|Theatre Arts', "business_majors" = 'Accounting|Finance|General Management|Global Management|Marketing', "engineering_majors" = 'Bioengineering|Chemical Engineering|Civil Engineering|Computer Engineering|Electrical Engineering|Engineering Physics|Industrial Engineering|Materials Science and Engineering|Mechanical Engineering', "professional_majors" = 'Administration of Justice|Applied Developmental Psychology|Architectural Studies|Athletic Training|Clinical Dietetics and Nutrition|Communication: Rhet & Comm|Communication Science|Dental Hygiene|Emergency Medicine|Health Information Management|Health Services|Health and Physical Activity|Information Science|Legal Studies|Media and Professional Communications|Nursing|Pharmacy|Public Service|Rehabilitation Science|Social Work', "updated_at" = '2013-06-22 14:26:19.324611' WHERE "colleges"."id" = 1
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/postgresql_adapter.rb:1161:in `async_exec'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/postgresql_adapter.rb:1161:in `exec_no_cache'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/postgresql_adapter.rb:671:in `block in exec_delete'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract_adapter.rb:280:in `block in log'
/app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract_adapter.rb:275:in `log'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/postgresql_adapter.rb:670:in `exec_delete'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract/database_statements.rb:96:in `update'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract/query_cache.rb:14:in `update'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/persistence.rb:359:in `update'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/locking/optimistic.rb:68:in `update'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/attribute_methods/dirty.rb:74:in `update'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/timestamp.rb:71:in `update'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/callbacks.rb:272:in `block in update'
/app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/callbacks.rb:403:in `_run__1124092128366785760__update__948523398122619999__callbacks'
/app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/callbacks.rb:405:in `__run_callback'
/app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/callbacks.rb:385:in `_run_update_callbacks'
/app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/callbacks.rb:81:in `run_callbacks'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/callbacks.rb:272:in `update'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/persistence.rb:348:in `create_or_update'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/callbacks.rb:264:in `block in create_or_update'
/app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/callbacks.rb:403:in `_run__1124092128366785760__save__948523398122619999__callbacks'
/app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/callbacks.rb:405:in `__run_callback'
/app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/callbacks.rb:385:in `_run_save_callbacks'
/app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/callbacks.rb:81:in `run_callbacks'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/callbacks.rb:264:in `create_or_update'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/persistence.rb:84:in `save'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/validations.rb:50:in `save'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/attribute_methods/dirty.rb:22:in `save'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/transactions.rb:259:in `block (2 levels) in save'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/transactions.rb:313:in `block in with_transaction_returning_status'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract/database_statements.rb:192:in `transaction'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/transactions.rb:208:in `transaction'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/transactions.rb:311:in `with_transaction_returning_status'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/transactions.rb:259:in `block in save'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/transactions.rb:270:in `rollback_active_record_state!'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/transactions.rb:258:in `save'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/persistence.rb:217:in `block in update_attributes'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/transactions.rb:313:in `block in with_transaction_returning_status'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract/database_statements.rb:192:in `transaction'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/transactions.rb:208:in `transaction'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/transactions.rb:311:in `with_transaction_returning_status'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/persistence.rb:215:in `update_attributes'
/app/db/seeds.rb:11:in `<top (required)>'
/app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:245:in `load'
/app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:245:in `block in load'
/app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:236:in `load_dependency'
/app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:245:in `load'
/app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/engine.rb:520:in `load_seed'
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/railties/databases.rake:347:in `block (2 levels) in <top (required)>'
/app/vendor/bundle/ruby/1.9.1/gems/rake-10.0.4/lib/rake/task.rb:246:in `call'
/app/vendor/bundle/ruby/1.9.1/gems/rake-10.0.4/lib/rake/task.rb:246:in `block in execute'
/app/vendor/bundle/ruby/1.9.1/gems/rake-10.0.4/lib/rake/task.rb:241:in `each'
/app/vendor/bundle/ruby/1.9.1/gems/rake-10.0.4/lib/rake/task.rb:241:in `execute'
/app/vendor/bundle/ruby/1.9.1/gems/rake-10.0.4/lib/rake/task.rb:184:in `block in invoke_with_call_chain'
/app/vendor/bundle/ruby/1.9.1/gems/rake-10.0.4/lib/rake/task.rb:177:in `invoke_with_call_chain'
/app/vendor/bundle/ruby/1.9.1/gems/rake-10.0.4/lib/rake/task.rb:170:in `invoke'
/app/vendor/bundle/ruby/1.9.1/gems/rake-10.0.4/lib/rake/application.rb:143:in `invoke_task'
/app/vendor/bundle/ruby/1.9.1/gems/rake-10.0.4/lib/rake/application.rb:101:in `block (2 levels) in top_level'
/app/vendor/bundle/ruby/1.9.1/gems/rake-10.0.4/lib/rake/application.rb:101:in `each'
/app/vendor/bundle/ruby/1.9.1/gems/rake-10.0.4/lib/rake/application.rb:101:in `block in top_level'
/app/vendor/bundle/ruby/1.9.1/gems/rake-10.0.4/lib/rake/application.rb:110:in `run_with_threads'
/app/vendor/bundle/ruby/1.9.1/gems/rake-10.0.4/lib/rake/application.rb:95:in `top_level'
/app/vendor/bundle/ruby/1.9.1/gems/rake-10.0.4/lib/rake/application.rb:73:in `block in run'
/app/vendor/bundle/ruby/1.9.1/gems/rake-10.0.4/lib/rake/application.rb:160:in `standard_exception_handling'
/app/vendor/bundle/ruby/1.9.1/gems/rake-10.0.4/lib/rake/application.rb:70:in `run'
Tasks: TOP => db:seed
(See full trace by running task with --trace)
~/collegeanswerz >>
模式:
ActiveRecord::Schema.define(:version => 20130613023113) do
create_table "colleges", :force => true do |t|
t.string "public"
t.string "years"
t.string "category"
t.string "calendar"
t.string "location"
t.string "setting"
t.integer "retention"
t.datetime "created_at", :null => false
t.datetime "updated_at", :null => false
t.integer "graduation4"
t.integer "graduation6"
t.string "degrees"
t.string "rotc"
t.integer "sat_submit"
t.integer "act_submit"
t.integer "sat_math_25"
t.integer "sat_math_75"
t.integer "sat_reading_25"
t.integer "sat_reading_75"
t.integer "sat_writing_25"
t.integer "sat_writing_75"
t.integer "sat_composite_25"
t.integer "sat_composite_75"
t.integer "act_math_25"
t.integer "act_math_75"
t.integer "act_reading_25"
t.integer "act_reading_75"
t.integer "act_writing_75"
t.integer "act_composite_25"
t.integer "act_composite_75"
t.integer "acceptance_rate"
t.integer "enrolled"
t.integer "gpa375"
t.integer "gpa35"
t.integer "gpa325"
t.integer "gpa3"
t.integer "gpa25"
t.integer "high_school_tenth"
t.integer "high_school_quarter"
t.integer "high_school_half"
t.integer "sat_math_700"
t.integer "sat_math_600"
t.integer "sat_math_500"
t.integer "sat_math_400"
t.integer "sat_math_300"
t.integer "sat_reading_700"
t.integer "sat_reading_600"
t.integer "sat_reading_500"
t.integer "sat_reading_400"
t.integer "sat_reading_300"
t.integer "sat_writing_700"
t.integer "sat_writing_600"
t.integer "sat_writing_500"
t.integer "sat_writing_400"
t.integer "sat_writing_300"
t.integer "act_composite_30"
t.integer "act_composite_24"
t.integer "act_composite_18"
t.integer "act_composite_12"
t.integer "act_math_30"
t.integer "act_math_24"
t.integer "act_math_18"
t.integer "act_math_12"
t.integer "act_reading_30"
t.integer "act_reading_24"
t.integer "act_reading_18"
t.integer "act_reading_12"
t.text "very_important"
t.text "important"
t.text "considered"
t.string "student_faculty"
t.integer "class_20"
t.integer "class_49"
t.integer "class_50"
t.text "majors"
t.integer "law"
t.integer "business"
t.integer "medical"
t.integer "other_grad"
t.integer "us_news_ranking"
t.text "top_25_grad"
t.integer "enrollment"
t.integer "graduate_enrollment"
t.integer "in_state"
t.integer "out_of_state"
t.integer "male"
t.integer "female"
t.text "ethnicity"
t.integer "frats"
t.integer "sororities"
t.integer "on_campus"
t.integer "freshman_on_campus"
t.integer "in_state_tuition"
t.integer "out_of_state_tuition"
t.integer "room_and_board"
t.integer "with_need_got_aid"
t.integer "got_need_fully_met"
t.integer "percent_need_met"
t.integer "scholarships"
t.integer "loans"
t.string "name"
t.string "url"
t.integer "act_writing_25"
t.integer "cost_30"
t.integer "cost_48"
t.integer "cost_75"
t.integer "cost_110"
t.integer "cost_111"
t.string "requirements"
t.string "ap_credit"
t.string "scholarships_link"
t.text "map"
t.text "street_view"
t.text "housing"
t.text "food"
t.text "weather"
t.text "dorms"
t.text "majors_offered_link"
t.text "science_majors"
t.text "social_science_majors"
t.text "humanities_majors"
t.text "business_majors"
t.text "engineering_majors"
t.text "professional_majors"
t.text "dorm_urls"
end
end
更新模式:
ActiveRecord::Schema.define(:version => 20130613023113) do
create_table "colleges", :force => true do |t|
t.string "public"
t.string "years"
t.string "category"
t.string "calendar"
t.string "location"
t.string "setting"
t.integer "retention"
t.datetime "created_at", :null => false
t.datetime "updated_at", :null => false
t.integer "graduation4"
t.integer "graduation6"
t.string "degrees"
t.string "rotc"
t.integer "sat_submit"
t.integer "act_submit"
t.integer "sat_math_25"
t.integer "sat_math_75"
t.integer "sat_reading_25"
t.integer "sat_reading_75"
t.integer "sat_writing_25"
t.integer "sat_writing_75"
t.integer "sat_composite_25"
t.integer "sat_composite_75"
t.integer "act_math_25"
t.integer "act_math_75"
t.integer "act_reading_25"
t.integer "act_reading_75"
t.integer "act_writing_75"
t.integer "act_composite_25"
t.integer "act_composite_75"
t.integer "acceptance_rate"
t.integer "enrolled"
t.integer "gpa375"
t.integer "gpa35"
t.integer "gpa325"
t.integer "gpa3"
t.integer "gpa25"
t.integer "high_school_tenth"
t.integer "high_school_quarter"
t.integer "high_school_half"
t.integer "sat_math_700"
t.integer "sat_math_600"
t.integer "sat_math_500"
t.integer "sat_math_400"
t.integer "sat_math_300"
t.integer "sat_reading_700"
t.integer "sat_reading_600"
t.integer "sat_reading_500"
t.integer "sat_reading_400"
t.integer "sat_reading_300"
t.integer "sat_writing_700"
t.integer "sat_writing_600"
t.integer "sat_writing_500"
t.integer "sat_writing_400"
t.integer "sat_writing_300"
t.integer "act_composite_30"
t.integer "act_composite_24"
t.integer "act_composite_18"
t.integer "act_composite_12"
t.integer "act_math_30"
t.integer "act_math_24"
t.integer "act_math_18"
t.integer "act_math_12"
t.integer "act_reading_30"
t.integer "act_reading_24"
t.integer "act_reading_18"
t.integer "act_reading_12"
t.text "very_important"
t.text "important"
t.text "considered"
t.string "student_faculty"
t.integer "class_20"
t.integer "class_49"
t.integer "class_50"
t.text "majors"
t.integer "law"
t.integer "business"
t.integer "medical"
t.integer "other_grad"
t.integer "us_news_ranking"
t.text "top_25_grad"
t.integer "enrollment"
t.integer "graduate_enrollment"
t.integer "in_state"
t.integer "out_of_state"
t.integer "male"
t.integer "female"
t.text "ethnicity"
t.integer "frats"
t.integer "sororities"
t.integer "on_campus"
t.integer "freshman_on_campus"
t.integer "in_state_tuition"
t.integer "out_of_state_tuition"
t.integer "room_and_board"
t.integer "with_need_got_aid"
t.integer "got_need_fully_met"
t.integer "percent_need_met"
t.integer "scholarships"
t.integer "loans"
t.string "name"
t.string "url"
t.integer "act_writing_25"
t.integer "cost_30"
t.integer "cost_48"
t.integer "cost_75"
t.integer "cost_110"
t.integer "cost_111"
t.text "requirements"
t.text "majors_offered"
t.text "ap_credit"
t.text "scholarships_link"
t.text "map"
t.text "street_view"
t.text "housing"
t.text "food"
t.text "weather"
t.text "dorms"
t.text "majors_offered_link"
t.text "science_majors"
t.text "social_science_majors"
t.text "humanities_majors"
t.text "business_majors"
t.text "engineering_majors"
t.text "professional_majors"
t.text "dorm_urls"
end
end
這看起來更像是一個電子表格而不是數據庫模式。我希望你的下一次「遷移」能使結構正常化至少3NF。 – wildplasser
我是新來的鐵軌,我不太熟悉我的選擇。這個想法是,我的網站爲每個學院都有一個頁面,我想通過擁有一個大學視圖並根據@ college.attribute更改視圖來保留我的代碼。用電子表格可以更容易嗎?如果是的話,我如何使用電子表格? –