Upgrade 3CX to v18 and get it hosted free!

Asterisk func DB_DELETE

Author image

Synopsis

Return a value from the Asterisk database and delete it

Syntax

DB_DELETE(<family>/<key>)

Description

This function will retrieve a value from the Asterisk database and then remove that key from the database. DB_RESULT will be set to the key’s value if it exists.

Examples

Example 1

exten => 1234,1,NoOp(${DB_DELETE(obst/apfel)})

Example 2

So here’s what you do to delete a database entry in 1.4.0:

exten => s,n,Set(oldval=${DB_DELETE(AGENT/${MACRO_EXTEN:1})})
; saves the old value of that key (in your case the callerid)
; into ${oldval} and deletes it from the DB. You can look at
; the value for the key you just deleted.
exten => s,n,NoOp(oldval : ${oldval})

See also

Related Posts:

Get 3CX - Absolutely Free!
Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.