FreePBX CDR ODBC recordingfile field not updating

Hi guys,

I am fighting here with this issue for 2 days now. I saw there was bug filed, but i am still experience the issue. Asterisk is latest 13.2.0 and FreePBX 12.x updated to latest version of modules.

The main issue is that CDR do not show play button. Problem is that recordingfile is not updated in mysql DB. Files are created and recordered in proper format. CDR(recordingfile) variable is also created and set. Dump of channel shows that recordingfile is also there and set. However odbc is not updating mysql.

Digging further i figured out that cdr_odbc.c has no field/column/variable for recordingfile variable used in the dialplan. I checked this on asterisk ver 11, 12 and 13 all is same.

The question is - how do you update that column from freepbx and what backend do you use? Do you use cdr_odbc for that and if that variable is missing in source code how should i expect to be filled?

Any advise is appreciate as i am fighting with this and seems no luck with it.

One more thing. If i set the callfilename manually in DB all is working fine on the web interface.

Thanks a lot.

Try following this tutorial:

Ok guys. I fixed it myself. Issue is with freepbx. In short is not able to record custom variables that are not defined in cdr_odbc.c unless you add them (patch/edit file on your own). The trick here is to disable and start using instead. In adaptive module all fields are seen by cdr module and all variables are populated properly. However if you use both in same time you will have double cdr entries for each call.

With adaptive odbc module there is a little issue where calldate is not updated and you see 0000000 only. To fix that you need to add alias in cdr_adaptive_odbc.conf


alias start => calldate

I am not sure why freepbx is not coming with odbc config files, but they should just make a note about this.