Project

General

Profile

Internal Server Error on setting a Date Custom Field to nothing

Added by James H about 9 years ago

I am getting an internal server error when I set a date custom field to nothing.

I have a custom field that is of data type: Date.
I have it filled in with a date (any is fine).
When I attempt to remove the date from the field, I receive an internal server error.
When I attempt to change the date, it works fine.

Anyone else getting this??

v.3.0.3


Started PATCH "//issues/33136" for [IPADDRESS] at 2015-06-03 09:25:03 -0700
Processing by IssuesController#update as HTML
  Parameters: {"utf8"=>"✓", "authenticity_token"=>"[TOKEN]", "issue"=>{"is_private"=>"0", "project_id"=>"949", "tracker_id"=>"4", "subject"=>"adsgdgsa", "description"=>"asdgsdgsadg", "status_id"=>"1", "priority_id"=>"1", "assigned_to_id"=>"", "parent_issue_id"=>"", "start_date"=>"", "due_date"=>"2015-06-24", "done_ratio"=>"0", "custom_field_values"=>{"349"=>"", "32"=>"", "33"=>"", "67"=>"", "63"=>"", "221"=>"", "209"=>"0", "362"=>"", "234"=>"", "237"=>"", "235"=>[""], "435"=>""}, "notes"=>"", "private_notes"=>"0", "lock_version"=>"2"}, "was_default_status"=>"1", "time_entry"=>{"hours"=>"", "activity_id"=>"", "comments"=>"", "custom_field_values"=>{"388"=>"", "387"=>""}}, "last_journal_id"=>"56009", "commit"=>"Submit", "id"=>"33136"}
  Current user: [user] (id=3)
Mysql2::Error: Illegal mix of collations (utf8_general_ci,IMPLICIT) and (latin1_swedish_ci,NUMERIC) for operation '>': INSERT INTO `journal_details` (`property`, `prop_key`, `old_value`, `value`, `journal_id`) VALUES ('cf', '32', '2015-06-17', '', 56013)
Completed 500 Internal Server Error in 889ms (ActiveRecord: 46.8ms)

ActiveRecord::StatementInvalid (Mysql2::Error: Illegal mix of collations (utf8_general_ci,IMPLICIT) and (latin1_swedish_ci,NUMERIC) for operation '>': INSERT INTO `journal_details` (`property`, `prop_key`, `old_value`, `value`, `journal_id`) VALUES ('cf', '32', '2015-06-17', '', 56013)):
  app/models/journal.rb:67:in `save'
  app/models/issue.rb:1566:in `create_journal'
  app/models/issue.rb:175:in `create_or_update'
  app/controllers/issues_controller.rb:479:in `block in save_issue_with_child_records'
  app/controllers/issues_controller.rb:467:in `save_issue_with_child_records'
  app/controllers/issues_controller.rb:180:in `update'

Illegal mix of collations with utf vs latin1... but all of my tables are set to utf... so not sure where its going wrong now.


Replies (2)

RE: Internal Server Error on setting a Date Custom Field to nothing - Added by James H about 9 years ago

Still same thing. wondering if anyone else gets this or if its just me.

RE: Internal Server Error on setting a Date Custom Field to nothing - Added by James H about 9 years ago

Solved.
Stupid database character sets and collations. i hate you

    (1-2/2)