Answer the question
In order to leave comments, you need to log in
How ASterisk get data from Mariadb table?
Hello!
I would like to set up a call to mobile phones in case the main one is not available.
Implementation with the help of a DB is necessary.
In Func_odbc.conf I have the following function:
[OPERATOR]
dsn=MySQL-asterisk
read=SELECT value FROM settings WHERE name='operator'
In dialplan:
'673' => 1. Answer() [pbx_config]
2. Set( operator=${ODBC_OPERATOR}) [pbx_config]
3. Noop(${operator}) [pbx_config]
In Verbose:
-- Executing [[email protected]:1] Answer("PJSIP/4102-00000013", "") in new stack
> 0x7f0fc4769c90 -- Probation passed - setting RTP source address to 192.168.0.206:16966
-- Executing [[email protected]:2] Set("PJSIP/4102-00000013", "operator=") in new stack
-- Executing [673 @outbound:3] NoOp("PJSIP/4102-00000013", "") in new stack -- Auto
fallthrough
, channel 'PJSIP/4102-00000013' status is 'UNKNOWN'
DB
Answer the question
In order to leave comments, you need to log in
easier through an external AGI script in a convenient language.
https://github.com/rillian/asterisk-opus/blob/mast...
write readsql everywhere
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question