This is a read-only copy of the MariaDB Knowledgebase generated on 2024-11-15. For the latest, interactive version please visit https://mariadb.com/kb/.

SHOW CREATE VIEW

Sintassi

SHOW CREATE VIEW nome_vista

Spiegazione

Restituisce l'istruzione CREATE VIEW necessaria per ricreare la vista specificata, oltre all'SQL_MODE che era attivo al momento della creazione e il set di caratteri che era usato dalla connessione.

SHOW CREATE VIEW virgoletta i nomi delle tabelle, delle colonne e delle Stored Function se richiesto dalla variabile sql_quote_show_create.

Esempi

SHOW CREATE VIEW example\G
*************************** 1. row ***************************
                View: example
         Create View: CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL
SECURITY DEFINER VIEW `example` AS (select `t`.`id` AS `id`,`t`.`s` AS `s` from
`t`)
character_set_client: cp850
collation_connection: cp850_general_ci

Con la variabile sql_quote_show_create impostata a off:

SHOW CREATE VIEW example\G
*************************** 1. row ***************************
                View: example
         Create View: CREATE ALGORITHM=UNDEFINED DEFINER=root@localhost SQL SECU
RITY DEFINER VIEW example AS (select t.id AS id,t.s AS s from t)
character_set_client: cp850
collation_connection: cp850_general_ci
Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.