Hi, Please tell me, How to save information in Asterisk DB?
adalson007 02-September-2008 02:00:04 PM

Comments



Storing Data in the AstDB

To store a new value in the Asterisk database, we use the Set() application, but instead
of using it to set a channel variable, we use it to set an AstDB variable. For example, to
assign the count key in the test family with the value of 1, write the following:
exten => 456,1,Set(DB(test/count)=1)
If a key named count already exists in the test family, its value will be overwritten with
the new value. You can also store values from the Asterisk command line, by running
the command database put family key value. For our example, you would type data
base put test count 1.

Posted by sagitraz


Direct save from CLI or set () application

Database put (Family Key Value)

Exten => 133, 1, Set ($ (DB (sample/private) = yes))

Posted by jackson



Posted: 03-September-2008 10:30:36 AM By: jackson

Direct save from CLI or set () application

Database put (Family Key Value)

Exten => 133, 1, Set ($ (DB (sample/private) = yes))

Posted: 05-September-2008 09:02:12 AM By: sagitraz


Storing Data in the AstDB

To store a new value in the Asterisk database, we use the Set() application, but instead
of using it to set a channel variable, we use it to set an AstDB variable. For example, to
assign the count key in the test family with the value of 1, write the following:
exten => 456,1,Set(DB(test/count)=1)
If a key named count already exists in the test family, its value will be overwritten with
the new value. You can also store values from the Asterisk command line, by running
the command database put family key value. For our example, you would type data
base put test count 1.