EDIT 2007/09/06: I've modified the sproc to change the dates to be formatted to 121 and stripped out all trailing spaces for char's
So, we don't have DBArtisan, but I am very happy for my copy of ERWin.
Read more →
Well, I did this originally to generate triggers for all tables in a database to audit data changes, and that is simple enough, just move the entire row from the deleted table to a mirrored audit table.
Read more →
This question comes up quit often. For example in this thread from dbForums SQL Server forum they are looking to do just that.
The simplest answer is to create a history for every table, then create a trigger for each that will move the entire row of the before image information into history when a DELETE or UPDATE Modification occurs.
Read more →
Thought I lost this...so I figured I better post it. It will create format cards for all tables in the database.
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].
Read more →
CREATE PROC isp_GenFormatCards AS DECLARE FormatCard CURSOR FOR SELECT FORMAT_CARD, TABLE_NAME, TABLE_SCHEMA FROM ( /* SELECT '--' + TABLE_NAME AS FORMAT_CARD , TABLE_NAME, null AS COLUMN_NAME, 0 AS SQLGroup, 1 AS RowGrouping FROM INFORMATION_SCHEMA.
Read more →