[asterisk-bugs] [JIRA] (ASTERISK-22298) [patch] Unexepected behaviour with adaptive odbc filter

Rusty Newton (JIRA) noreply at issues.asterisk.org
Wed Aug 14 17:53:07 CDT 2013


Rusty Newton created ASTERISK-22298:
---------------------------------------

             Summary: [patch] Unexepected behaviour with adaptive odbc filter
                 Key: ASTERISK-22298
                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-22298
             Project: Asterisk
          Issue Type: Bug
      Security Level: None
          Components: CDR/cdr_adaptive_odbc
    Affects Versions: 11.4.0
            Reporter: Jordi Llull Chavarría
            Severity: Minor


I was playing with our CDR configuration and I found an annoying behaviour when trying to replace the src column in some cases. My {{cdr_adaptive_odbc.conf}} contains something like this:

[replace-src]
connection=asterisk
table=cdr
alias source => src
filter source != 

[dont-replace-src]
connection=asterisk
table=cdr
filter source =>

So if you set CDR(source) in the dialplan it works great. However if you don't set it it'll insert two rows in the CDR. That's because it won't check filters if the value is not set! The attached patch solves the problem by avoiding inserting the CDR if the column is not set and there's a non-blank filter for it.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.asterisk.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira



More information about the asterisk-bugs mailing list