[Asterisk-Users] Using ',' character in applications data
Nik Martin
nmartin at radiancetech.com
Mon Apr 26 13:51:16 MST 2004
I think the proposal is to have your application just take the items in the
select as arguments to your AGI app:
Exten => 1,1,MySQLAGIAPP(Item1,Item2,Item3)
Where the arguments might be used in your app to form the query:
Select * from foo where col1='item1', col2='item2',col3='item3'
-----Original Message-----
From: asterisk-users-admin at lists.digium.com
[mailto:asterisk-users-admin at lists.digium.com] On Behalf Of GUSTAVO GARCIA
BERNARDO
Sent: Monday, April 26, 2004 2:39 PM
To: asterisk-users at lists.digium.com
Subject: Re: [Asterisk-Users] Using ',' character in applications data
Thank you very much.
1. The problem with ',' is worked around using the syntax: exten =>
1,1,MYSQL,"INSERT INTO services user,service VALUES ${callerid},voicemail"
instead of exten => 1,1,MYSQL(INSERT INTO services (user,service) VALUES
(${callerid},voicemail)
2. About using SQL statements in extensions.conf, i would like to hear your
proposed to improve the application. In first instance, I choose SQL
statemens to offer maximum flexibility, because current postgres application
allow it too and to avoid the administrator the learning of other syntax.
Best regards.
G.
----- Mensaje original -----
De: Jeremy McNamara <jj at nufone.net>
Fecha: Martes, Abril 27, 2004 9:03 pm
Asunto: Re: [Asterisk-Users] Using ',' character in applications data
> GUSTAVO GARCIA BERNARDO wrote:
>
> >I'm developping an application for asterisk and i need to pass SQL
> querys with ',' character as data.
> >exten => 1,1,Sql(SELECT info,user FROM.....
> >
> >
>
> Come on....build the application properly. There is absolutely no
> need
> for one to have SQL statements in your extensions.conf file. Just
> pass
> in the required info to your application and build the SQL
> statement in
> the application, then set channel variable(s) if necessary.
>
>
> You have to be smarter than what your working on.
>
>
>
> Jeremy McNamara
>
>
> _______________________________________________
> Asterisk-Users mailing list
> Asterisk-Users at lists.digium.com
> http://lists.digium.com/mailman/listinfo/asterisk-users
> To UNSUBSCRIBE or update options visit:
> http://lists.digium.com/mailman/listinfo/asterisk-users
>
_______________________________________________
Asterisk-Users mailing list
Asterisk-Users at lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users
More information about the asterisk-users
mailing list