salix/db/routines/psico/views/examView.sql

13 lines
342 B
MySQL
Raw Permalink Normal View History

CREATE OR REPLACE DEFINER=`root`@`localhost`
SQL SECURITY DEFINER
VIEW `psico`.`examView`
AS SELECT `q`.`text` AS `text`,
`eq`.`examFk` AS `examFk`,
`eq`.`questionFk` AS `questionFk`,
`eq`.`answerFk` AS `answerFk`,
`eq`.`id` AS `id`
FROM (
`psico`.`question` `q`
JOIN `psico`.`examQuestion` `eq` ON(`q`.`id` = `eq`.`questionFk`)
)