03-24-2009 02:17 AM - edited 03-14-2019 03:50 AM
HI All
I am having some trouble working out how i would reterive data from a database. I'm basically trying to send an account number to a DB and get it to return some fields which i can display in CAD.
What is the easiest was to do this? Using ICM or CVP. I cannot find that much info on setting it up for either.
Does any one have some basic examples on a script or setting it up i can take a look at?
Thanks for your help,
Matt
03-24-2009 01:34 PM
I'm a Java programmer - so for me, by far the easiest way is to use a custom Action Element in CVP VXML. I actually run a complicated stored procedure (the input is the calling line ID) through the native Microsoft SQL Java driver and get back a structured string which I return to ICM in caller_input. Then I pull it apart using the ICM substring function.
You could also use the built-in Database Element. I'm not a huge fan of it myself, but if you cannot build custom Java elements, it's what you need.
Regards,
Geoff
07-19-2009 11:28 AM
Geoff,
Are you returning this to caller_input through the subdialog return? all the FromExtVXML's come through fine, but caller_input isn't. 4.0(2) no SR's.
Thanks!
Chad
07-20-2009 01:09 AM
We have 4.0(2) at this customer. Yep - user.microapp.caller_input, mate. Have you enabled this ECC variable? Is it long enough?
caller_input has to work. It has a red star next to it in Studio - it's mandatory. If you don't put something in this field CVP will run your VXML application again.
You have to be doing something odd.
Regards,
Geoff
07-20-2009 11:34 AM
Geoff,
As you said I went back and double checked and in my ICM scripts after my app played I was doing Call.microapp.caller_input = Call.PeripheralVariable10 instead of
Call.PeripheralVariable10 = Call.microapp.caller_input
Man to much work makes silly mistakes, thanks for renforcing that it works, I knew it was insane.
Chad
07-21-2009 09:32 AM
Good work Chad. I have also made that mistake with the ICM set node. Too much work - I hear you.
I have found that the Find tool is a pretty useful check at the end of a lot of scripting. If you choose the right thing for your search, or open up a number of scripts all at once and then search the open scripts, you can normally find a few mistakes where you have built a number of scripts from a prototype that you are then changing slightly. This has helped me a few times.
A REALLY GOOD naming convention can help you contain the silly mistakes, too.
Regards,
Geoff
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide