Home  >  Article  >  Database  >  How does navicat see triggers?

How does navicat see triggers?

angryTom
angryTomOriginal
2019-08-08 11:25:2615499browse

How does navicat see triggers?

Trigger is a method provided by SQL server to programmers and data analysts to ensure data integrity. It is a special stored procedure related to table events. Its execution is not called by a program or started manually, but is triggered by events. For example, its execution is activated when a table is operated (insert, delete, update). Below we will introduce to you how to view the created triggers in Navicat.

Related recommendations: navicat cracked version download

1. Select the specified database, Then select "Others" and "Triggers" in sequence

How does navicat see triggers?

2. How to view the written triggers Trigger statement

Right-click trigger name--->Object information--->DDL

How does navicat see triggers?

##Extended information: Trigger classification

DML trigger

When the data in the table in the database changes, including insert, update ,delete any operation, if we write the corresponding DML trigger to the table, then the trigger will be executed automatically. The main function of DML triggers is to enforce business rules and extend Sql Server constraints, default values, etc. Because we know that constraints can only constrain data in the same table, while triggers can execute any Sql command.

DDL trigger

It is a new trigger in Sql Server2005. It is mainly used to audit and standardize the structure of tables, triggers, views, etc. in the database. operate. For example, modifying tables, modifying columns, adding new tables, adding new columns, etc. It is executed when the database structure changes. We mainly use it to record the modification process of the database and to restrict programmers from modifying the database, such as not allowing deletion of certain specified tables.

Login trigger

The login trigger will fire the stored procedure in response to the LOGIN event. This event is raised when a user session is established with an instance of SQL Server. The login trigger will fire after the authentication phase of the login is complete but before the user session is actually established. Therefore, all messages from within triggers that would normally reach the user (such as error messages and messages from PRINT statements) are passed to the SQL Server error log. If authentication fails, the login trigger will not fire.



The above is the detailed content of How does navicat see triggers?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn