All Manuals > LispWorks® User Guide and Reference Manual > 45 The SQL Package

commit Function

Summary

Commits changes made to a database.

Package

sql

Signature

commit &key database => nil

Arguments
database
A database.
Description

The function commit commits changes made to the database specified by database, which is *default-database* by default.

Examples

This example changes records in a database, and uses commit to make those changes permanent.

(insert-records :into [emp]
               :attributes '(x y z)
               :values '(a b c))
(update-records [emp]
   :attributes [dept]
   :values 50
   :where [= [dept] 40])
(delete-records :from [emp]
   :where [> [salary] 300000])
(commit)
See also

*default-database*
rollback
with-transaction


LispWorks® User Guide and Reference Manual - 01 Dec 2021 19:30:56