• SOLVED: How to change field-type of existing metadata fields?

  • OpenKM has many interesting features, but requires some configuration process to show its full potential.
OpenKM has many interesting features, but requires some configuration process to show its full potential.
Forum rules: Please, before asking something see the documentation wiki or use the search feature of the forum. And remember we don't have a crystal ball or mental readers, so if you post about an issue tell us which OpenKM are you using and also the browser and operating system version. For more info read How to Report Bugs Effectively.
 #47409  by OpaHeinz
 
Short explanation:
For the moment, to add invoice documents I use a textfield in metadata to enter and store supplier names.
Now I uploaded a couple of invoices and assigned my metadata to it which means I assigned the supplier name and number in the described textfield.
so far so fine

Now I would like to change my textfield in a field which delivers suggestion out of still existing suppliernumbers.
Would this be possible?
If yes, how?

I assume, that I have to
1) read my still existing "supplier name" field and deliver a unique and alphabetical ordered list
2) provide this list in the metadata input mask as a selection

But what is, if I have an invoice with a new, for OpenKM unknown supplier?
In this case I should enter it again as a text....

It would be great If I could get some hints or used scenarios

Thank you in advance
rds Heinz
Last edited by OpaHeinz on Tue Feb 12, 2019 9:09 am, edited 1 time in total.
 #47454  by OpaHeinz
 
Yes, I still had a look on it.

Until now I had view hundred documents with assigned supplier by a text field.
Can I change the fieldtype for the existing/ still assigned documents?
(I don't want to loose the still assigned data)

Thank you in advance
rgds
Heinz
 #47466  by dferguson
 
You want to change documents with "text field data" to the equivalent which are now listed in a select list?

How about finding all the documents by group name of the text filed with a SQL query? You could then update the group name with the new group name and value. Write a script or other external program to sort based on text field value and apply the new value to match.
 #47484  by jllort
 
If you are playing in a production environment I suggest a backup.
Also, a good practice might be playing with another environment ( cloned production or OpenKM personal development environment and from there play safely ).

About Us

OpenKM is part of the management software. A management software is a program that facilitates the accomplishment of administrative tasks. OpenKM is a document management system that allows you to manage business content and workflow in a more efficient way. Document managers guarantee data protection by establishing information security for business content.