2

Performing a heroku db:push

everything seem to be going ok

Sending schema Schema: 100% |==========================================| Time: 00:00:05 Sending indexes schema_migrat: 100% |=====================================| Time: 00:00:00 users: 100% |==========================================================| Time: 00:00:01 histories: 100% |========================================================| Time: 00:00:00 Sending data 4 tables, 587 records

schema_migrat: 100% |==============================================| Time: 00:00:00

when i get

/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/date.rb:1573:in new_by_frags': ArgumentError: invalid date (Sequel::InvalidValue) from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/date.rb:1618:inparse' from /Library/Ruby/Gems/1.8/gems/sequel-3.17.0/lib/sequel/core.rb:222:in string_to_datetime' from /Library/Ruby/Gems/1.8/gems/sequel-3.17.0/lib/sequel/timezones.rb:92:inconvert_input_timestamp' from /Library/Ruby/Gems/1.8/gems/sequel-3.17.0/lib/sequel/timezones.rb:163:in convert_timestamp' from /Library/Ruby/Gems/1.8/gems/sequel-3.17.0/lib/sequel/timezones.rb:46:indatabase_to_application_timestamp'

EDIT: Adding Schema/Migration

t.string "apothiki" 
t.string "timh" 
t.datetime "created_at" 
t.datetime "updated_at" 
t.string "photo_file_name" 
t.string "photo_content_type" 
t.integer "photo_file_size" 
t.datetime "photo_updated_at"
cbrulak
  • 15,436
  • 20
  • 61
  • 101
elkalto23
  • 267
  • 3
  • 12
  • please post your migration/schema. Heroku uses PostgreSQL so there is probably a difference between the date types. – cbrulak Jan 23 '11 at 23:47
  • t.string "apothiki" t.string "timh" t.datetime "created_at" t.datetime "updated_at" t.string "photo_file_name" t.string "photo_content_type" t.integer "photo_file_size" t.datetime "photo_updated_at" – elkalto23 Jan 23 '11 at 23:54
  • that's your entire schema? nothing looks weird. – cbrulak Jan 23 '11 at 23:59
  • Did you do a heroku db:migrate first? – cbrulak Jan 24 '11 at 00:03
  • did you see this question: http://stackoverflow.com/questions/1634693/problem-pushing-sqlite3-db-to-heroku-lib-taps-schema-rb30in-sqlite-config – cbrulak Jan 24 '11 at 01:00
  • thanks however i dont understand i must generate a different schema.rb than the one i have now ? – elkalto23 Jan 24 '11 at 01:15
  • what database vendor are you currently using (SQLite, MySQL, etc)? – cbrulak Jan 24 '11 at 05:18
  • SQlite , i also installed the pg gem thought it might help but still the same problem – elkalto23 Jan 24 '11 at 11:29
  • Ok, i was importing my data from an CSV file but all my datetimes from created and modified were empty, and that wasnt a problem with sqlite deploying locally. once i filled proper dates to all the records it sure pushed the db okay. so solved! thanks for the help! – elkalto23 Jan 24 '11 at 12:37
  • cool. you should answer your own question in case others come across this issue. – cbrulak Jan 24 '11 at 16:08

1 Answers1

0

Ok, i was importing my data from an CSV file but all my datetimes from created and modified were empty, and that wasnt a problem with sqlite deploying locally. once i filled proper dates to all the records it sure pushed the db okay. so solved! thanks for the help!

elkalto23
  • 267
  • 3
  • 12