summaryrefslogtreecommitdiff
path: root/configs/samples/cdr_adaptive_odbc.conf.sample
diff options
context:
space:
mode:
authorMatthew Jordan <mjordan@digium.com>2014-07-17 21:17:28 +0000
committerMatthew Jordan <mjordan@digium.com>2014-07-17 21:17:28 +0000
commitfc0fecb4768d696db3324bcf6dd03325bb4cd513 (patch)
tree12615f96e88382b2824d4901f6949571e41ea2e4 /configs/samples/cdr_adaptive_odbc.conf.sample
parent1ce23d4534994fdd8bfb8ad3b9ca1884194097be (diff)
configs: Move sample config files into a subdirectory of configs
This moves all samples configs from configs/ to configs/samples. This allows for additional sets of sample configuration files to be added in the future. Review: https://reviewboard.asterisk.org/r/3804/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@418870 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'configs/samples/cdr_adaptive_odbc.conf.sample')
-rw-r--r--configs/samples/cdr_adaptive_odbc.conf.sample60
1 files changed, 60 insertions, 0 deletions
diff --git a/configs/samples/cdr_adaptive_odbc.conf.sample b/configs/samples/cdr_adaptive_odbc.conf.sample
new file mode 100644
index 000000000..f3c806e75
--- /dev/null
+++ b/configs/samples/cdr_adaptive_odbc.conf.sample
@@ -0,0 +1,60 @@
+; The point of this module is to allow you log whatever you like in terms of
+; the CDR variables. Do you want to log uniqueid? Then simply ensure that
+; your table has that column. If you don't want the column, ensure that it
+; does not exist in the table structure. If you'd like to call uniqueid
+; something else in your table, simply provide an alias in the configuration
+; file that maps the standard CDR field name (uniqueid) to whatever column
+; name you like. Perhaps you'd like some extra CDR values logged that aren't
+; in the standard repertoire of CDR variables (some that come to mind are
+; certain values used for LCR: route, per_minute_cost, and per_minute_price).
+; Simply set those CDR variables in your dialplan, i.e. Set(CDR(route)=27),
+; ensure that a corresponding column exists in your table, and cdr_adaptive_odbc
+; will do the rest.
+;
+; This configuration defines the connections and tables for which CDRs may
+; be populated. Each context specifies a different CDR table to be used.
+;
+; The columns in the tables should match up word-for-word (case-insensitive)
+; to the CDR variables set in the dialplan. The natural advantage to this
+; system is that beyond setting up the configuration file to tell you what
+; tables to look at, there isn't anything more to do beyond creating the
+; columns for the fields that you want, and populating the corresponding
+; CDR variables in the dialplan. For the builtin variables only, you may
+; create aliases for the real column name.
+;
+; Please note that after adding columns to the database, it is necessary to
+; reload this module to get the new column names and types read.
+;
+; Warning: if you specify two contexts with exactly the same connection and
+; table names, you will get duplicate records in that table. So be careful.
+;
+
+;[first]
+;connection=mysql1
+;table=cdr
+
+;[second]
+;connection=mysql1
+;table=extracdr
+
+;[third]
+;connection=sqlserver
+;table=AsteriskCDR
+;schema=public ; for databases which support schemas
+;usegmtime=yes ; defaults to no
+;alias src => source
+;alias channel => source_channel
+;alias dst => dest
+;alias dstchannel => dest_channel
+;
+; Any filter specified MUST match exactly or the CDR will be discarded
+;filter accountcode => somename
+;filter src => 123
+; Negative filters are also now available
+;filter src != 456
+;
+; Additionally, we now support setting static values per column. The reason
+; for this is to allow different sections to specify different values for
+; a certain named column, presumably separated by filters.
+;static "Some Special Value" => identifier_code
+