salix/db/routines/vn/views/ticketLastUpdated.sql

8 lines
291 B
MySQL
Raw Permalink Normal View History

2024-08-20 08:06:10 +00:00
CREATE OR REPLACE DEFINER=`vn`@`localhost`
SQL SECURITY DEFINER
VIEW `vn`.`ticketLastUpdated`
AS SELECT `ticketLastUpdatedList`.`ticketFk` AS `ticketFk`,
max(`ticketLastUpdatedList`.`created`) AS `lastUpdated`
FROM `vn`.`ticketLastUpdatedList`
GROUP BY `ticketLastUpdatedList`.`ticketFk`