function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
LIM AI KHOONLIM AI KHOON 

Change data that associate with apex class.

Hi, I think this question is falls under general development.

Currently, my orgs have an apex class. That class connects with server-PI, where data from SAP will flow to our CRM for an account object [sync function]. Some existing fields are text fields. So now my user requests to change the field from text to picklist. Is it okay if we simply change like usual? because it's already associated with the apex class that captures data from SAP to CRM. If I change that, is it will impact they sync function?
mukesh guptamukesh gupta
Hi LIM,

Please don't try this it can be a big impact on exisitng functionality 
  • If you want to change the custom field of ‘Text’ type to ‘Picklist’, the new picklist field will automatically pickup current distinct values from the text field (upto a maximum of 250).
  • Changing from Text to Picklist of an existing custom field can cause data loss 

if you need any assistanse, Please let me know!!

Kindly mark my solution as the best answer if it helps you.

Thanks
Mukesh