Hi All
I need to change one of my custom fields from 'Text Field' tp 'Free Text'.
Please let me know your suggestions.
Thanks
Vishnu.
As a possibly safer alternative to the above, you can try the copy custom field values function from the script runner plugin. So you could copy Ref Testcase to "Ref testcase new", verify everything looks OK, delete "Ref Testcase", then rename Ref Testcase New to Ref Testcase.
Advantage of this is that you don't need downtime to do it.
http://confluence.atlassian.com/display/JIRA042/Changing+Custom+Field+Types
Thanks Deepnight,
I already got this.
"UPDATE customfieldvalue SET textvalue=stringvalue WHERE ID=(SELECT ID FROM customfield WHERE
UPDATE
customfieldvalue
SET
textvalue=stringvalue
WHERE
ID=(
SELECT
ID
FROM
customfield
customfieldtypekey=
'com.atlassian.jira.plugin.system.customfieldtypes:textfield'
AND
cfname=
'Text Field'
);"
No, that SQL is correct - note the use of the "cfname" in the selection, you need to replace 'Text Field' with the actual name of your custom field that you want to change.
Thanks to Both. You are right !!!
I faced another problem. I ran the following queries.
1. 1. UPDATE customfieldvalue SET textvalue=stringvalue WHERE ID=(SELECT ID FROM customfield WHEREcustomfieldtypekey='com.atlassian.jira.plugin.system.customfieldtypes:textfield' AND cfname='Ref. Testcase');
2. UPDATE customfield SET CUSTOMFIELDTYPEKEY='com.atlassian.jira.plugin.system.customfieldtypes:textarea', CUSTOMFIELDSEARCHERKEY='com.atlassian.jira.plugin.system.customfieldtypes:textsearcher'where cfname='Ref. Testcase';
The first one didn't change anything as The table ' customfieldvalue' doesn't have an entry for this field.
I avoided this and ran the second one which changed the field type. Restarted the JIRA, I lost values in this field of all issues. But the type has been chaged.
I guess the problem was I haven't changes the values to 'stringvalue'.
Do we have ant other table which keeps this liek 'customfieldvalue' ? This is JIRA 4.0.1.
Regards
Thanks Jamie.
Sounds good. But is it possible to move values from one field to another using Jelly Runner ?
I do not prefer installing plugins.
Please offer your opinions.
Thanks, Vishnu.
In theory it's possible with jelly runner, in practice not so much, not unless someone has already written how.
It looks like you're new here. Sign in or register to get started.