Are `AS`'s in `SELECT * FROM mytable AS t` and `CREATE VIEW AS (…)` the same command?

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP


Are `AS`'s in `SELECT * FROM mytable AS t` and `CREATE VIEW AS (…)` the same command?



In PostgreSQL,


SELECT * FROM mytable AS t;

CREATE VIEW v AS (SELECT * FROM mytable);



In terms of syntax, are AS's in the above two commands


AS



different clauses of SELECT command and of CREATE VIEW command respectively?


SELECT


CREATE VIEW



or the same command themselves?



Thanks.





Why you are faced such a question?
– Hamlet Hakobyan
6 mins ago





It's not a "command", it's a keyword that introduces an alias
– a_horse_with_no_name
2 mins ago









By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Popular posts from this blog

Keycloak server returning user_not_found error when user is already imported with LDAP

PHP parse/syntax errors; and how to solve them?

415 Unsupported Media Type while sending json file over REST Template