sql. SQL-query returning no result

^void:sql{SQL-query}
^void:sql{SQL-query}
[$.bind[variables hash]] [3.1.4]

This method sends SQL-query that returns no result (operations on data management in a database). For this method to work, you must have connection with DB-server established (see operator
connect).

It is possible to use additional parameter with the constructor:
$.bind[hash] - variables to bind, see «Queries with bound variables» [3.1.4].

Example
^connect[connect string]{
   ^void:sql{
create table users(id int,name text,email text)}
}

As a result of this code's work, new table users will be created. The query will return no result. This example is for MySQL DBMS.


Copyright © 1997–2021 Art. Lebedev Studio | http://www.artlebedev.com Last updated: 21.09.2007