9 lines
290 B
MySQL
9 lines
290 B
MySQL
|
CREATE OR REPLACE DEFINER=`root`@`localhost`
|
||
|
SQL SECURITY DEFINER
|
||
|
VIEW `vn`.`firstTicketShipped`
|
||
|
AS SELECT min(`vn`.`ticket`.`shipped`) AS `shipped`,
|
||
|
`vn`.`ticket`.`clientFk` AS `clientFk`
|
||
|
FROM `vn`.`ticket`
|
||
|
WHERE `vn`.`ticket`.`shipped` > '2001-01-01'
|
||
|
GROUP BY `vn`.`ticket`.`clientFk`
|