Manual Reset | Enable Automatic Reset | Disable Automatic Reset
There is no UI configured way to trigger the reset of Log, Checklist, Incident, or Lost and Found numbering. These procedures require executing one or more SQL commands on the Database Server.
Manual Reset
Any or all of the counters can be manually reset.
To manually reset the numbering for the Daily Logs, use the following SQL command:
UPDATE AutoInc SET ID = 0 WHERE Name like 'DailyLogNumber';
To manually reset the numbering for the Checklists, use the following SQL command:
UPDATE AutoInc SET ID = 0 WHERE Name like 'ChecklistNumber';
To manually reset the numbering for the Incident Reports, use the following SQL command:
UPDATE AutoInc SET ID = 0 WHERE Name like 'IncidentNumber';
To manually reset the numbering for the Lost and Found, use the following SQL commands:
UPDATE AutoInc SET ID = 0 WHERE Name like 'LostItemNumber';
UPDATE AutoInc SET ID = 0 WHERE Name like 'FoundItemNumber';
To manually reset the numbering for all reporting items, use the following SQL command:
UPDATE AutoInc SET ID = 0 WHERE Name IN ('ChecklistNumber', 'DailyLogNumber', 'IncidentNumber', 'LostItemNumber', 'FoundItemNumber');
Enable Automatic Reset
Any or all of the counters can be configured to automatically reset on the first of the year.
To configure automatic reset for the Daily Logs, use the following SQL commands:
IF EXISTS (SELECT * FROM VisualCasino.dbo.AutoInc WHERE Name like 'DailyLogNumber')
BEGIN
UPDATE VisualCasino.dbo.AutoInc SET ResetYear = getdate() WHERE Name like 'DailyLogNumber';
END
ELSE
BEGIN
INSERT INTO VisualCasino.dbo.AutoInc (ID, Name, ResetYear) VALUES (0, 'DailyLogNumber', getDate())
END
To configure automatic reset for the Checklists, use the following SQL commands:
IF EXISTS (SELECT * FROM VisualCasino.dbo.AutoInc WHERE Name like 'ChecklistNumber')
BEGIN
UPDATE VisualCasino.dbo.AutoInc SET ResetYear = getdate() WHERE Name like 'ChecklistNumber';
END
ELSE
BEGIN
INSERT INTO VisualCasino.dbo.AutoInc (ID, Name, ResetYear) VALUES (0, 'ChecklistNumber', getDate())
END
To configure automatic reset for the Incident Reports, use the following SQL commands:
IF EXISTS (SELECT * FROM VisualCasino.dbo.AutoInc WHERE Name like 'IncidentNumber')
BEGIN
UPDATE VisualCasino.dbo.AutoInc SET ResetYear = getdate() WHERE Name like 'IncidentNumber';
END
ELSE
BEGIN
INSERT INTO VisualCasino.dbo.AutoInc (ID, Name, ResetYear) VALUES (0, 'IncidentNumber', getDate())
END
To configure automatic reset for the Lost and Found, use the following SQL commands:
IF EXISTS (SELECT * FROM VisualCasino.dbo.AutoInc WHERE Name like 'LostItemNumber')
BEGIN
UPDATE VisualCasino.dbo.AutoInc SET ResetYear = getdate() WHERE Name like 'LostItemNumber';
END
ELSE
BEGIN
INSERT INTO VisualCasino.dbo.AutoInc (ID, Name, ResetYear) VALUES (0, 'LostItemNumber', getDate())
END
IF EXISTS (SELECT * FROM VisualCasino.dbo.AutoInc WHERE Name like 'FoundItemNumber')
BEGIN
UPDATE VisualCasino.dbo.AutoInc SET ResetYear = getdate() WHERE Name like 'FoundItemNumber';
END
ELSE
BEGIN
INSERT INTO VisualCasino.dbo.AutoInc (ID, Name, ResetYear) VALUES (0, 'FoundItemNumber', getDate())
END
To configure automatic reset for all of the reporting items, execute all of the above SQL commands.
Disable Automatic Reset
To disable automatic reset for the Daily Logs, use the following SQL command:
UPDATE VisualCasino.dbo.AutoInc SET ResetYear = null WHERE Name like 'DailyLogNumber';
To disable automatic reset for the Checklists, use the following SQL command:
UPDATE VisualCasino.dbo.AutoInc SET ResetYear = null WHERE Name like 'ChecklistNumber';
To disable automatic reset for the Incident Reports, use the following SQL command:
UPDATE VisualCasino.dbo.AutoInc SET ResetYear = null WHERE Name like 'IncidentNumber';
To disable automatic reset for the Lost and Found, use the following SQL commands:
UPDATE VisualCasino.dbo.AutoInc SET ResetYear = null WHERE Name like 'LostItemNumber';
UPDATE VisualCasino.dbo.AutoInc SET ResetYear = null WHERE Name like 'FoundItemNumber';
To disable automatic reset for all of the reporting items, execute the following SQL command:
UPDATE VisualCasino.dbo.AutoInc SET ResetYear = null WHERE Name IN ('DailyLogNumber', 'ChecklistNumber', 'IncidentNumber', 'LostItemNumber', 'FoundItemNumber');