Re: [asterisk-dev] extra parameter for DB read function

2006-05-31 Thread Julian Lyndon-Smith
Hey, no bubble to burst - I'm always up for finding an easier way. I didn't realise that just by checking the existence of a pair it stored it in a variable. OTOH it *is* more yeuch to read. All of those $ { [ are s easy to misplace, and sooo easy to misread and not find the problem. And

Re: [asterisk-dev] extra parameter for DB read function

2006-05-31 Thread Jared Smith
On Wed, 2006-05-31 at 14:30 +0100, Julian Lyndon-Smith wrote: > There are often times that I want to read a DB value from the dialplan, > and if this family/key pair does not exist, set it to some default value. > > for example: > > 1234,1 => Set(EMAILADDR=${DB(x/y)} > 1234,2 => GotoIf($["${EMAI

[asterisk-dev] extra parameter for DB read function

2006-05-31 Thread Julian Lyndon-Smith
There are often times that I want to read a DB value from the dialplan, and if this family/key pair does not exist, set it to some default value. for example: 1234,1 => Set(EMAILADDR=${DB(x/y)} 1234,2 => GotoIf($["${EMAILADDR}" = ""]?3:4) 1234,3 => Set([EMAIL PROTECTED]) 1234,4 => NoOp(${EMAILA