exten=>_x.,1,Answer()
same=>n,Queue(support,,,,,,,insert,,)
[insert]
exten=>s,1,Noop(var values are ${d} ${CALLERID(num)} ${EXTEN})
same=>n,System(mysql --user=root --password='1234' asterisk -e "INSERT INTO calls (number,extension) values ('${CALLERID(num)}','${EXTEN}')")
same=>n,System(mysql --user=root --password='1234' asterisk -e "INSERT INTO calls (number,extension) values ("11","1")")
same=>n,return()
first query give error mysql unknown in field list when using double quote and the values to insert was a letter instead of a number for example Solved
Note
$name = "my name"
$query = " INSERT INTO mytable VALUES ( 1 , '$name') "
Note that although the query is enclosed between double quotes, you must enclose any string in single quotes.
http://stackoverflow.com/questions/1346209/unknown-column-in-field-list-error-on-mysql-update-query
No hay comentarios:
Publicar un comentario