4

I created custom field "rec_name" id table "cdr", database "asteriskcdrdb". In this field I want to store recording name. I know I should do it by adding this line in one of .conf files, but where?

exten => s,1,set(CDR(rec_name)=${CALLFILENAME})

I can do it by sql statement, too, but I don't know where is the file that saves details of call into database.

voy
  • 1,568
  • 2
  • 17
  • 28

1 Answers1

3

For mysql you need add into /etc/asterisk/cdr_mysql.conf

[aliases]
rec_name=rec_name

If you HAVE aliases section, just add to it

rec_name=rec_name
arheops
  • 15,544
  • 1
  • 21
  • 27
  • 3
    In current versions (1.8+) there are no need do such aliases. Just need add field to DB table and restart asterisk or do cdr_mysql.so unload/load. – arheops Jun 16 '14 at 08:34
  • `module reload cdr_mysql.so` for Asterisk 1.8.20.1, I needed to add the alias in cdr_mysql.conf – Jorge V. Feb 23 '17 at 22:31