1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-11-27 07:37:33 +00:00

; Fix last change in sqlite.c

* etc/NEWS:
* doc/lispref/text.texi (Database):
* src/sqlite.c (Fsqlite_execute_batch): Fix last change (Bug#70145).
This commit is contained in:
Eli Zaretskii 2024-06-06 13:06:58 +03:00
parent 7ba4de0077
commit 9da2faf73b
3 changed files with 11 additions and 11 deletions

View File

@ -5417,8 +5417,8 @@ called @var{gif}, you have to mark it specially to let
@defun sqlite-execute-batch db statements
Execute the @acronym{SQL} @var{statements}. @var{statements} is a
string containing 0 or more @acronym{SQL} statements. This command
might be useful when we want to execute multiple @acronym{DDL}
statements.
might be useful when a Lisp program needs to execute multiple Data
Definition Language (@acronym{DDL}) statements in one go.
@end defun

View File

@ -485,10 +485,10 @@ its shebang line, Emacs will now skip over 'env -S' and deduce the
major mode based on the interpreter after 'env -S'.
+++
** New command 'sqlite-execute-batch'.
This command lets the user execute multiple SQL commands in one
command. It is useful when the user wants to evaluate an entire SQL
file.
** New function 'sqlite-execute-batch'.
This function lets the user execute multiple SQL statements in one go.
It is useful, for example, when a Lisp program needs to evaluate an
entire SQL file.
+++

View File

@ -647,13 +647,13 @@ sqlite_exec (sqlite3 *sdb, const char *query)
}
DEFUN ("sqlite-execute-batch", Fsqlite_execute_batch, Ssqlite_execute_batch, 2, 2, 0,
doc: /* Execute multiple SQL statements in DB.
Query is a string containing 0 or more SQL statements. */)
(Lisp_Object db, Lisp_Object query)
doc: /* Execute multiple SQL STATEMENTS in DB.
STATEMENTS is a string containing 0 or more SQL statements. */)
(Lisp_Object db, Lisp_Object statements)
{
check_sqlite (db, false);
CHECK_STRING (query);
Lisp_Object encoded = encode_string(query);
CHECK_STRING (statements);
Lisp_Object encoded = encode_string (statements);
return sqlite_exec (XSQLITE (db)->db, SSDATA (encoded));
}