Article Preview
Buy Now
COLUMN
Triggers and Orphans
A Brief Discussion on SQL
Issue: 20.2 (March/April 2022)
Author: Vince Du Beau
Author Bio: Vince is an experienced Filemaker developer. He is exploring XOJO as an alternative to Filemaker.
Article Description: No description available.
Article Length (in bytes): 3,915
Starting Page Number: 84
Article Number: 20209
Related Link(s): None
Excerpt of article text...
Triggers are used to initiate an action during certain database events such as an
insert ,update , ordelete . They can be designed to occur either before or after the event.Developers usually design them to work at the row level. They can also be specified to run based on a specific statement.
I worked on a project a few years back when using UUIDS (Universally Unique IDs) was all the rage in the Filemaker community for primary keys. I wanted to see if I could do it with SQLite. An example trigger to create a UUID when inserting a new customer record follows:
`CREATE TRIGGER CustomerGenerateGUID
AFTER INSERT ON Customer
...End of Excerpt. Please purchase the magazine to read the full article.