Verileri alanın içinde alfabetik sırayla koyabilir miyim? / Can I put the data inside the field in alphabetical order? #Salesforce Developer
7 risposte
@Ali Can Kara Do we have a trigger implemented for account if yes then we can use that to sort the data. Or else implement a flow and call this invocable apex, pass the account id as parameter and populate an output parameter with the sorted description.
Below is the basic sorting logic which you can implement:
String str='B,A,C';// test data
List<String> lstOfString = str.split(',');
lstOfString.sort();
string sortedDescString = string.join(lstOfString,',');// Hold the sorted description
System.debug(sortedDescString);// testing the output
Hope this helps