Author: Michelle McCausland
Note: Use the queries in the sections below to learn how these tables are linked together.
Contacts are types of users that are assigned to network elements via contact responsibilities.
Contacts and contact responsibilities are utilised in the Tickteter application to denote the owner of tickets ( Smart Users ) or determine the distribution of ticket notifications ( Introduction to email templates (creation, modification) and fields ) .
Information on adding, updating and deleting contacts can be found in the SNMP Manager Admin User Guide which is available on the Errigal support page.
Contact responsibilities denote a contact's responsibility for a network element.
Information on adding, updating and deleting contact responsibilities can be found in the SNMP Manager Admin User Guide which is available on the Errigal support page.
For reference only - please verify all SQL statements before executing.
SELECT cr.contact_id as contactId, c.first_name, ' ' , c.last_name) as login, cr.responsibility_type as responsibilityType, ne.id as elementId, ne.name as neName FROM snmp_manager.contact c JOIN snmp_manager.contact_responsibility cr ON c.id = cr.contact_id JOIN snmp_manager.network_element ne ON cr.element_id = ne.id WHERE cr.contact_id = <ID OF CONTACT>;
For reference only - please verify all SQL statements before executing.
INSERT INTO contact_responsibility (version, element_id, rank, responsibility_type, contact_id) (SELECT 0 AS version, cr.element_id AS element_id, cr.rank AS rank, cr.responsibility_type AS responsibility_type, [id of contact that is being copied TO] AS contact_id FROM contact_responsibility cr JOIN contact co ON co.id = cr.contact_id WHERE co.id = [id of contact that is being copied FROM]);
For reference only - please verify all SQL statements before executing.
INSERT INTO contact_responsibility (version, element_id, rank, responsibility_type, contact_id) (SELECT 0 AS version, [id of element that is being copied TO] AS element_id, cr.rank AS rank, cr.responsibility_type AS responsibility_type, cr.contact_id AS contact_id FROM contact_responsibility cr JOIN network_element ne ON ne.id = cr.element_id WHERE ne.id = [id of element that is being copied FROM]);