This month's discount Comprehensive Database Performance Health Check · Testimonials
SQLAuthority with Pinal Dave
Home
  • Consulting
    • Health Check
  • Free Videos
  • All Articles
    • AI
    • SQL Performance
    • SQL Tips and Tricks
    • Interview Questions and Answers
    • SQL Puzzle
    • SQL Video
    • SQLAuthority News
    • Personal
  • Books
  • Consulting
SQL SERVER - Be Careful with Logon Triggers - Don’t use Host_Name

SQL SERVER – Be Careful with Logon Triggers – Don’t use Host_Name

April 14, 2018
Pinal Dave
SQL Tips and Tricks
SQL Error Messages, SQL Login, SQL Scripts, SQL Server, SQL Trigger, Starting SQL

A reader used HOST_NAME() in a logon trigger to limit access. Here is why that is risky, and why Logon Triggers can lock everyone out if you are not careful.

Read More
Title card: Msg 217: Nesting Level Exceeded (Limit 32)

SQL SERVER – Nested Triggers – Trigger Calling Another Trigger Error

January 29, 2018
Pinal Dave
SQL Tips and Tricks
SQL Scripts, SQL Server, SQL Trigger

A reader asked what happens when one trigger calls another. Here is a simple example with two AFTER INSERT triggers that shows how nested triggers behave.

Read More
One coat on a single hook by a door, with four wet coats heaped on the floor beneath

Triggers That Assume One Row: Fixing Them for Multi-Row Updates

February 1, 2017
Pinal Dave
SQL Tips and Tricks
SQL Audit, SQL Server, SQL Transactions, SQL Trigger

Fix triggers for multi-row updates by joining inserted and deleted, testing complete audit coverage, and keeping transaction work small.

Read More
Migration feature table.

Oracle to SQL SERVER Migration – Triggers Used While Migration

December 28, 2016
Pinal Dave
SQL Tips and Tricks
Oracle, SQL Migration, SQL Trigger

Moving from Oracle to SQL Server is like switching phones: old habits come along. A client tuning case about the triggers used during the migration.

Read More
SQL SERVER - How to Avoid Triggers for Multiple Row Operations in a Table

SQL SERVER – How to Avoid Triggers for Multiple Row Operations in a Table

October 20, 2016
Pinal Dave
SQL Tips and Tricks
SQL Scripts, SQL Server, SQL Trigger

A late-night mail from an old customer about an application error led to this lesson: how to avoid triggers causing trouble with multiple row operations.

Read More
SQL SERVER - How to Enable or Disable All the Triggers on a Table and Database?

SQL SERVER – How to Enable or Disable All the Triggers on a Table and Database?

September 5, 2015
Pinal Dave
SQL Tips and Tricks
SQL Scripts, SQL Trigger

One line commands to enable or disable all the triggers on a table, a database or the whole server using ENABLE TRIGGER ALL and DISABLE TRIGGER ALL.

Read More
A chessboard mid-game on a cafe table with empty chairs, one knight off its square, two cold cups of coffee.

Who Changed This Row? Auditing Data Changes

June 10, 2015
Pinal Dave
SQL Tips and Tricks
Change Data Capture, SQL Audit, SQL Server, SQL Trigger, Temporal Table

Auditing data changes requires choosing whether you need old values, new values, actor identity, or a change feed, then testing the cost.

Read More
Previous 1 2 3 4 5 6 … 8 Next
  • Books
  • Testimonials
  • Privacy Policy

© 2006 – 2026 All rights reserved. pinal @ SQLAuthority.com