The simplest case which might show the utility of this new module is a replacement for the DB command:
func_odbc.conf:
[ASTDB]
dsn=mysql1
read=SELECT astvalue FROM astdb WHERE astfamily='${ARG1}' AND astkey='${ARG2}'
write=REPLACE INTO astdb (astfamily, astkey, astvalue) VALUES ('${ARG1}','${ARG2}','${VALUE}')
extensions.conf:
exten => _XXX,1,Set(open=${ODBC_ASTDB(office,open)})
...
; 600 turns the system off, 601 turns the system on
exten => _60[01],1,Set(ODBC_ASTDB(office,open)=${EXTEN:2})