all i need is just to read some value from MySQL into a variable in Asterisk
i googled alot for connecting Astreisk with MySQL, came accross many solutions, one of them was ‘Asterisk cmd MySQL’, but some how not able to make work even one, i did every thing described in it http://www.voip-info.org/wiki/index.php?page=Asterisk+cmd+MYSQL & herez my dialplan
exten => 999, 1, Wait()
exten => 999, 2, Answer()
exten => 999, 3, Playback(connecting)
exten => 999,4,MYSQL(Connect connid localhost root acdacd asteriskdb)
;exten => 999,4,MYSQL(Connect connid 172.16.1.209 root dbpass asteriskdb)
exten => 999,5,MYSQL(Query resultid ${connid} SELECT\ Number\ from\ number\ where\ test=11)
exten => 999,6,MYSQL(Fetch fetchid ${resultid} var1)
exten => 999,7,MYSQL(Clear ${resultid})
exten => 999,8,MYSQL(Disconnect ${connid})
…
i compile Asterisk, it gets compiled but when i dial 999, it executes ‘Wait’, ‘Answer’, ‘Playback’ but shows error while executing MYSQL(Connect connid localhost root acdacd asteriskdb)…it says something is failed while executing this statement (unfortunately i forgot to get the exact error log on CLI)
i tried it again without any password to the root@localhost for MySQL(asteriskDB) n many more combinitions but all in vain…the same error
anybody plz help me in it, or tell me the whole step-by-step process if some1 can