mysqlquery to insert data into MySQL [message #92088] |
Thu, 08 October 2015 05:01  |
huangsu
Messages: 10 Registered: November 2014
|
Junior Member |
|
|
Using Marc Buie's IDL library, I can use 'mysqlquery' to retrieve data from MySQL, with syntax of:
mysqlquery, lun, 'SELECT Col1, Col2 FROM Table1;', v1, v2, format = '(A,A)';
However, I don't know the syntax to insert data using mysqlquery. How do I pass the data into the query string?
Anyone can help? Many thanks!
Regards,
|
|
|
Re: mysqlquery to insert data into MySQL [message #92091 is a reply to message #92088] |
Fri, 09 October 2015 13:02   |
penteado
Messages: 866 Registered: February 2018
|
Senior Member Administrator |
|
|
I have this function to crate a MySQL table from an IDL structure. It may be what you want:
http://ppenteado.net/idl/pp_lib/doc/pp_structtomysql.html#pp _structtomysql
The inverse operation (MySQL table into an IDL structure array) is done by
http://ppenteado.net/idl/pp_lib/doc/pp_mysqlquery.html
On Thursday, October 8, 2015 at 5:01:29 AM UTC-7, Sullivan wrote:
> Using Marc Buie's IDL library, I can use 'mysqlquery' to retrieve data from MySQL, with syntax of:
>
> mysqlquery, lun, 'SELECT Col1, Col2 FROM Table1;', v1, v2, format = '(A,A)';
>
> However, I don't know the syntax to insert data using mysqlquery. How do I pass the data into the query string?
>
> Anyone can help? Many thanks!
>
> Regards,
|
|
|
|