![]() ![]() Triggers are database operations that are automatically performed when a specified database event occurs. The CREATE TRIGGER statement is used to add triggers to the database schema. The statement CREATE TRIGGER creates a new trigger in SQLite. an insert, update or delete) occurs for the table/views. It supports the declaration of local variables, statements to control the flow of the procedure, assignment of expression results to variables, and error handling.Ī trigger is a named database object that is associated with a table, and it activates when a particular event (e.g. It supports constructs that are common to most programming languages. Implementation of SQL triggers is based on the SQL standard. All rules run on the server before the result returns. Improve performance in client/server environment.If a business policy changes, you need to change only the corresponding trigger program instead of each application program. Define a trigger once and then reuse it for any application that uses the database. Because the database stores triggers, you do not have to code the trigger actions into each database application. Replicate data to different files to achieve data consistency.Query from other files for cross-referencing purposes.Write to other files for audit trail purposes. ![]()
0 Comments
Leave a Reply. |