Using ODBCFinish


I am following Getting Funky with func_odbc: Hot-Desking. I have a query that gets a list of ID’s and extensions to chose from. As soon as the user hears what they want they enter the number. The IVR sounds like this:
If you know the extension you want you can enter it at any time, to hear a list of extensions press 0. If they press 0 then I connect to the DB to get a list of options. I looked up what ODBCFinish does and it seems to clear up any left over data once we are done. Since a user and press any number in middle what happens if I don’t call ODBCFinish? Does it keep anything “hanging”? Does it hurt to call ODBCFinish whenever someone enters an extension to clear a multi row select?

It won’t leak memory, but if you don’t ODBCFinish then the information will stick with the channel until it hangs up. It doesn’t hurt anything to call it afterwards.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.