Posted by Anonymous Wed 21st Mar 2007 17:04 - Syntax is None/text - 30 views
Download | New Post | Modify | Hide line numbers
  1. /* extensions.conf snippet */
  2. exten => 5705,1,Answer()
  3. exten => 5705,n,Set(ODBC_CREATEACTIVECALL()=${STRFTIME(||%m/%d/%Y %T.000)}\,${UNIQUEID}\,${CALLERID(number)}\,${QUEUENAME}\,CALL\,${CHANNEL})
  4. exten => 5705,n,NoOp(this next one works)
  5. exten => 5705,n,Set(ODBC_UPDATEACTIVECALL2(${UNIQUEID},cAcceptCall\,cOutboundResult,\'${CHANNEL}\'\,\'${EXTEN}\')=)
  6. exten => 5705,n,NoOp(this next one is broken)
  7. exten => 5705,n,Set(ODBC_UPDATEACTIVECALL2(${UNIQUEID},cAcceptCall\,cOutboundResult,'${CHANNEL}'\,'${EXTEN}')=)
  8. exten => 5705,n,Hangup()
  9.  
  10.  
  11. /* func_odbc.conf snippet*/
  12. [UPDATEACTIVECALL2]
  13. dsn=mydb
  14. write=UPDATE PUB.ActiveCall SET (${ARG2}) = (${ARG3}) WHERE cCallID = '${ARG1}'
  15.  
  16. /* verbose snippet */
  17.  
  18. Accepting call from '01702123456' to '54321' on channel 0/1, span 1
  19.     -- Executing [54321@isdn32-a:1] Goto("Zap/1-1", "common|5705|1") in new stack
  20.     -- Goto (common,5705,1)
  21.     -- Executing [5705@common:1] Answer("Zap/1-1", "") in new stack
  22.     -- Executing [5705@common:2] Set("Zap/1-1", "ODBC_CREATEACTIVECALL()=03/21/2007 17:01:57.000,1174496517.757,01702123456,,CALL,Zap/1-1") in new stack
  23.     -- Executing [5705@common:3] NoOp("Zap/1-1", "this next one works") in new stack
  24.     -- Executing [5705@common:4] Set("Zap/1-1", "ODBC_UPDATEACTIVECALL2(1174496517.757|cAcceptCall,cOutboundResult|'Zap/1-1','5705')=") in new stack
  25.     -- Executing [5705@common:5] NoOp("Zap/1-1", "this next one is broken") in new stack
  26.     -- Executing [5705@common:6] Set("Zap/1-1", "ODBC_UPDATEACTIVECALL2(1174496517.757|cAcceptCall,cOutboundResult|Zap/1-1,5705)=") in new stack
  27. [Mar 21 17:01:57] WARNING[13421]: func_odbc.c:84 generic_prepare: SQL Prepare failed![UPDATE PUB.ActiveCall SET (cAcceptCall,cOutboundResult) = (Zap/1-1,5705) WHERE cCallID = '1174496517.757']
  28. [Mar 21 17:01:57] WARNING[13421]: res_odbc.c:125 ast_odbc_prepare_and_execute: SQL Prepare failed.  Attempting a reconnect...
  29. [Mar 21 17:01:57] WARNING[13421]: res_odbc.c:460 odbc_obj_disconnect: res_odbc: disconnected 0 from mydb [mydb]
  30. [Mar 21 17:01:57] NOTICE[13421]: res_odbc.c:502 odbc_obj_connect: Connecting mydb
  31. [Mar 21 17:01:57] NOTICE[13421]: res_odbc.c:516 odbc_obj_connect: res_odbc: Connected to mydb [mydb]
  32. [Mar 21 17:01:57] WARNING[13421]: func_odbc.c:84 generic_prepare: SQL Prepare failed![UPDATE PUB.ActiveCall SET (cAcceptCall,cOutboundResult) = (Zap/1-1,5705) WHERE cCallID = '1174496517.757']
  33. [Mar 21 17:01:57] WARNING[13421]: res_odbc.c:125 ast_odbc_prepare_and_execute: SQL Prepare failed.  Attempting a reconnect...
  34. [Mar 21 17:01:57] WARNING[13421]: res_odbc.c:460 odbc_obj_disconnect: res_odbc: disconnected 0 from mydb [mydb]
  35. [Mar 21 17:01:57] NOTICE[13421]: res_odbc.c:502 odbc_obj_connect: Connecting mydb
  36. [Mar 21 17:01:57] NOTICE[13421]: res_odbc.c:516 odbc_obj_connect: res_odbc: Connected to mydb [mydb]
  37.     -- Executing [5705@common:7] Hangup("Zap/1-1", "") in new stack
  38.   == Spawn extension (common, 5705, 7) exited non-zero on 'Zap/1-1'
  39.     -- Hungup 'Zap/1-1'
  40.  

PermaLink to this entry https://pastebin.co.uk/12122
Posted by Anonymous Wed 21st Mar 2007 17:04 - Syntax is None/text - 30 views
Download | New Post | Modify | Hide line numbers

 

Comments: 0