CREATE OR REPLACE DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `vn2008`.`albaran_state` AS SELECT `dn`.`id` AS `albaran_state_id`, `dn`.`state` AS `state` FROM `vn`.`deliveryNoteState` `dn`