Adding userfield with FreePBX


Where is the best place within the FreePBX .conf files to populate userfield for the current cdr record? I tried to add this line to [macro-record-enable], but it seems to get ignored.

exten => s,999,Set(CDR(userfield)=${CALLFILENAME}.gsm)

I have seen it be “set” in the asterisk CLI, but with no effect on the table record. So, I am assuming there is a proper or better place to populate this field. Can you help?



To enable the use of the userfield edit the /etc/asterisk/cdr_mysql.conf file and add this line: userfield=1

once that has been edited you need to restart asterisk.

Thank you, fskrotzki. I guess I should have caught that on the site.