bwenzel@cleartel.com Report post Posted 07/06/2006 03:38 PM Support, I have an IVR that connects to about 10 different servers to access the databases. We had an issue that came up where the circuit was down and the IVR was unable to access one of the databases. Rather than getting the system error and dropping the calls, is there a way to have some kind of fail over that transfers the call? I have tried for testing purposes to set the "fail" of the VB script module to play a certain wav file and the "success" to play another. The fail worked but the success was always routed to fail. Even though I did not show any system vbscript error pop up on the console. I know for a fact that the success definately works. When testing the fail, I just changed the ip of the database to make the error. Please let me know if you know a workaround to this problem. Cleartel Communications Share this post Link to post
SupportTeam Report post Posted 07/07/2006 10:57 AM Rather than getting the system error and dropping the calls, is there a way to have some kind of fail over that transfers the call? You should be able to use the error message returned as the path trigger code. Then the script will take this path upon encountering the error and you can point that path to a Transfer Call module. Can you post any traces (vgm) of a database query during which that database was inaccessible? I have tried for testing purposes to set the "fail" of the VB script module to play a certain wav file and the "success" to play another. The fail worked but the success was always routed to fail. Please post the VG script used and the trace of a call. Share this post Link to post
bwenzel@cleartel.com Report post Posted 07/13/2006 08:55 PM For the error event handling in vbscript i used on error resume next this is a piece of the code .... set CmdSP = CreateObject("ADODB.Command") set VG = CreateObject("VoiceGuide.CommandLink") On Error Resume Next CmdSP.ActiveConnection = "Provider=SQLOLEDB;Server=xxx.xxx.xxx.xxx;UID=xxx;PWD=xxx;Database=orderMana ement" CmdSP.CommandText = "dbo.IVR_Prepaid" CmdSP.CommandType = 4 CmdSP.Parameters.Append CmdSP.CreateParameter("RETURN_VALUE", adInteger, adParamReturnValue, 4) CmdSP.Parameters.Append CmdSP.CreateParameter("@phone", adVarChar, adParaminput, 12, $RV[TN]) Set adoRS = CmdSP.Execute If Err.Number <> 0 Then VG.RvSet $RV_LINEID, "sqlerror", 1 End If OK, sqlerror is a variable already initialized to 0. So when we cannot connect to the database, sqlerror is set to 1. Then we have an evaluate module that says on 0 go here or 1 go there. This works on my workstation as well as the server "console" with and without making it error out. When we run this as a vbscript without error in voiceguide it works great. sqlerror stays assigned to 0 and takes the proper route. When we make it error, such as using an incorrect password, the module hangs forever. Never assigning the value to 1. Please let me know if you have any suggestions Share this post Link to post
SupportTeam Report post Posted 07/13/2006 09:22 PM Quite possibly it's the CmdSP.Execute that does not return immediately... Try placing some Admin_TraceLogAdd function calls before and after CmdSP.Execute and see if the corresponing entries appearing in the log file. You can use Admin_TraceLogAdd function to trace execution of VBScripts in general. Share this post Link to post