aboutsummaryrefslogtreecommitdiffstats
path: root/cdr
diff options
context:
space:
mode:
authorjeremy <jeremy@f38db490-d61c-443f-a65b-d21fe96a405b>2004-01-11 06:01:02 +0000
committerjeremy <jeremy@f38db490-d61c-443f-a65b-d21fe96a405b>2004-01-11 06:01:02 +0000
commit30b19f362485828e92c575e04bb6e30238220a93 (patch)
tree1de81587ac6e7d03e4890e745df72adfefa4c00f /cdr
parente2093074c78cc9985dc2d0fc3d75a169cc1cb5c5 (diff)
Log cdr user data, if enabled
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@1931 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'cdr')
-rwxr-xr-xcdr/cdr_odbc.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/cdr/cdr_odbc.c b/cdr/cdr_odbc.c
index fddd68834..cfe2864df 100755
--- a/cdr/cdr_odbc.c
+++ b/cdr/cdr_odbc.c
@@ -73,8 +73,8 @@ static int odbc_log(struct ast_cdr *cdr)
{
sprintf(sqlcmd,"INSERT INTO cdr "
"(calldate,clid,src,dst,dcontext,channel,dstchannel,lastapp,"
- "lastdata,duration,billsec,disposition,amaflags,accountcode,uniqueid) "
- "VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)");
+ "lastdata,duration,billsec,disposition,amaflags,accountcode,uniqueid,userfield) "
+ "VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)");
}
else
{
@@ -144,6 +144,7 @@ static int odbc_log(struct ast_cdr *cdr)
if((loguniqueid != NULL) && ((strcmp(loguniqueid, "1") == 0) || (strcmp(loguniqueid, "yes") == 0)))
{
SQLBindParameter(ODBC_stmt, 15, SQL_PARAM_INPUT, SQL_C_CHAR, SQL_CHAR, 0, 0, cdr->uniqueid, 0, NULL);
+ SQLBindParameter(ODBC_stmt, 16, SQL_PARAM_INPUT, SQL_C_CHAR, SQL_CHAR, 0, 0, cdr->userfield, 0, NULL);
}
if(connected)