Hi Glen,
Firstly, use the below udf code which gives you the system name and pass the output of this to a fix value, and pass the output of this to the target field.
In this way, for every environment, the udf returns the exact system name, in the fixvalues, maintain accordingly the value pair for the system key.
Regards
Vishnu