[asterisk-users] How to query a remote MySQL DB from dialplan

Michiel van Baak michiel at vanbaak.info
Mon Aug 25 13:21:27 CDT 2008


On 13:12, Mon 25 Aug 08, Rich wrote:
> I want to query an existing MySQL DB from my Asterisk Dialplan.
> This to check one field in a table in a database on a remote DB server.
> 
> Is this possible using 'app_addon_sql_mysql' from asterisk-addons pkg?
> 
> I would like to use an ODBC connector eg. unixODBC.
> I would like it to be 'stock', ie. part of the standard release and supported
> into the future.
> 
> I have researched this for a couple days now (Asterisk Wiki and maillist)
> and am confused by the many and varied  'solutions' I find online.
> 
> I so far haven't been able to navigate thru all the online docs to a real solution.
> If I am finally successful... I will contribute a step by step HOWTO to the Wiki.
> 
> Any hints and pointers will be greatly appreciated.
> Thanks,
> Rich

If you want to use ODBC, there's no need to use app_addon_sql_mysql.
This addon uses native mysql, instead of odbc.

If you want something stock that is in default asterisk base package
have a look at func_odbc. 
It matches your requirements (odbc, stock, standard release, supported
in the future) and is a very nice tool to get used to.

-- 

Michiel van Baak
michiel at vanbaak.eu
http://michiel.vanbaak.eu
GnuPG key: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x71C946BD

"Why is it drug addicts and computer aficionados are both called users?"




More information about the asterisk-users mailing list