sc_begin_trans("Connection")

This macro starts a set of transactions in the database.

In form applications, the events that can run this macro is dependent of the database update (onAfterInsert, onAfterUpdate, onAfterDelete, onBeforeInsert, onBeforeUpdate or onBeforeDelete), they are automatically protected through transaction control, since the connection is the same of the application.

In the other cases, if the user wish to make transaction control, must begin with this macro and finish with the "sc_commit_trans()" macro to confirm the updates or "sc_rollback_trans" to cancel the transactions.

The "connection" parameter is optional, necessary only if the command is executed in a different database from the specified application.