Asterisk 13 -> ForkCDR, and different field values

Hello,

I am using Asterisk 13 for a new simple deployment that will cover voicemail, call forwarding and the calling and receiving calls. This system is connected to a SIP devices. I am allowing the phones to set a call forwarding so that every time they receive a call, it is forwarded to that number they chose. The thing is that if there are many “jumps” between devices that forward the calls to each other, I want to have an independent CDR entry in the database for every “jump”.

I try to force the creation of a new CDR with the ForkCDR application, and they changing the userfield by doing Set(CDR(userfield)=value) in the dialplan. The problem I have is that every new CDR row that is created get always the value of the last Set for the userfield.

exten => 111,1,NoOp(ForkCDR test) same => n,Set(CDR(userfield)=hello) same => n,ForkCDR(<using or without using the v option>) same => n,Set(CDR(userfield)=world) same => n,Hangup()

In this case both CDR records will have “world” as the value of the userfield. How can I do to set a different value for userfield when forking a CDR? Is this thing a limitation introduced by the refactor done with CDR in version 12? If there is no way to do that with the current applications, I will modify Asterisk source code to introduce the funcionality that I need, but I prefer to ask first.

Thank you so much for your time!
Javier