Author: Michelle McCausland
Example ticket CCSUPPORT-1493
Support, The 5 elements attached shown have completed PM or ACC tickets with close dates dating over two years ago. Why didn’t the Q2 PMs generate for these items?.
After some investigation we determined that these maintenances were marked as expired in the maintenance table which means they would not ticket.
To find the cause of this issue:
Retrieve the maintenance entries related to these elements:
SELECT id, current_open_ticket_id, external_element_id, expired FROM maintenance WHERE external_element_id IN (2581,2948,3347,3352,5076);
| maintenance_id | external_element_id | Expired |
|---|---|---|
| 2874 | 2948 | 1 |
| 3273 | 3347 | 1 |
| 3278 | 3352 | 1 |
| 5002 | 5076 | 1 |
To correct this issue:
cd logs/grails tail -f Ticketer.log
UPDATE maintenance SET expired = false where external_element_id IN (2581,2948,3347,3352,5076);
select ee.id, ee.name, m.next_ticket_date
FROM external_element ee join maintenance m on m.external_element_id = ee.id
WHERE ee.name IN ('METROPCS->MTR_NY_NYH05_01(NYH005)', 'METROPCS->MTR_NY_NYH11_01(NYH011)', 'METROPCS->MTR_NY_NYH13_02(NYH013)', 'METROPCS->MTR_NY_NYH18_04(NYH018)');
| id | name | next_ticket_date |
| 7183 | METROPCS→MTR_NY_NYH05_01(NYH005) | 2016-04-01 00:00:00 |
| 7191 | METROPCS→MTR_NY_NYH11_01(NYH011) | 2016-04-01 00:00:00 |
| 7202 | METROPCS→MTR_NY_NYH13_02(NYH013) | 2016-04-01 00:00:00 |
| 7238 | METROPCS→MTR_NY_NYH18_04(NYH018) | 2016-04-01 00:00:00 |
select next_ticket_date from maintenance where external_element_id in (2581,2948,3347,3352,5076);
| next_ticket_date |
| 2016-07-01 00:00:00 |
| 2016-07-01 00:00:00 |
| 2016-07-01 00:00:00 |
| 2016-07-01 00:00:00 |
| 2016-07-01 00:00:00 |