Reference custom field in another custom field

Is it possible to reference a custom field in another field?

Creating custom field custom_1

Creating custom field custom_2
emit(doc['custom_1'].value)

I get the following error
No field found for [custom_1] in mapping

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.