From: Tilghman Lesher Date: Fri, 11 Jan 2008 18:30:00 +0000 (+0000) Subject: Commit Nick Gorham's suggestion for timestamp fix X-Git-Tag: 1.6.0-beta1~3^2~83 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ed3007e7b32d64e8c54a87a7f3d45507012b4c33;p=thirdparty%2Fasterisk.git Commit Nick Gorham's suggestion for timestamp fix git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@98268 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/cdr/cdr_odbc.c b/cdr/cdr_odbc.c index 4f7b5cdbd5..af02d393ce 100644 --- a/cdr/cdr_odbc.c +++ b/cdr/cdr_odbc.c @@ -74,12 +74,12 @@ static SQLHSTMT prepare_cb(struct odbc_obj *obj, void *data) snprintf(sqlcmd,sizeof(sqlcmd),"INSERT INTO %s " "(calldate,clid,src,dst,dcontext,channel,dstchannel,lastapp," "lastdata,duration,billsec,disposition,amaflags,accountcode,uniqueid,userfield) " - "VALUES ('%s',?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)", table, timestr); + "VALUES ({ts '%s'},?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)", table, timestr); } else { snprintf(sqlcmd,sizeof(sqlcmd),"INSERT INTO %s " "(calldate,clid,src,dst,dcontext,channel,dstchannel,lastapp,lastdata," "duration,billsec,disposition,amaflags,accountcode) " - "VALUES ('%s',?,?,?,?,?,?,?,?,?,?,?,?,?)", table, timestr); + "VALUES ({ts '%s'},?,?,?,?,?,?,?,?,?,?,?,?,?)", table, timestr); } ODBC_res = SQLAllocHandle(SQL_HANDLE_STMT, obj->con, &stmt);