Project

General

Profile

How to change text custom fields to long text in one query.

Added by Chris Maeda over 7 years ago

We recently upgraded Redmine from 2.1 to 3.3 and I got tasked with changing some text custom fields to long text.

Details here: http://blog.cmaeda.com/2016/09/changing-custom-field-types-in-redmine.html

Next up is changing list custom fields to version custom fields.


Replies (1)

RE: How to change text custom fields to long text in one query. - Added by Michal Rysiak about 3 years ago

It's actually much simpler. You can just update the custom_fields table, changing the field_format value from 'string' to 'text' for the custom field of your choice (selected by id in the example), like this:
update custom_fields set field_format='text' where id=<...>;

Tested and works great!

    (1-1/1)