[asterisk-users] func_odbc creating records or best practice

Tilghman Lesher tilghman at mail.jeffandtilghman.com
Mon Apr 28 18:17:01 CDT 2008


On Monday 28 April 2008 17:30, Robert McNaught wrote:
> I am trying to write a custom application which will integrate with an
> existing MSSQL crm system.
>
> We need to get ahold of the CDR(uniqueid) field in during call-time -
> I see from doing a DumpChan(), the CDR unique ID is available as soon
> as the call is created.  CDRs usind odbc are only written once the
> call is completed.  Does anyone know if it is possible to use
> func_odbc to create a temporary record then delete it so that this
> information is available to MSSQL.  I was not sure if func_odbc was
> limited to just using UPDATE/SELECT queries.

func_odbc can do whatever queries you give it.  SELECT/UPDATE are
simply the simplest cases that make it easy to understand the functionality.

> Would there be a better way to do this using the AMI or AGI?  It just
> seems a little strange to use a database for storing temporary data
> such as this?

I'd agree with you on that.  I would tend to set variables directly in the
channel, then query them out using AMI.

-- 
Tilghman



More information about the asterisk-users mailing list