Earlier versions of Hive did not enable us to ALTER the view once it was generated, but this limitation has been removed in the later versions.
Please keep in mind that the syntax below applies not just to SQL but also to Apache Hive and Cloudera’s Impala.
ALTER VIEW view_name AS SELECT…
CREATE VIEW Emp_View
SELECT * FROM Emp WHERE DeptNo IN(10,20);
ALTER VIEW Emp_View
SELECT * FROM Emp WHERE DeptNo IN(10,20,30);
Hope you find this article helpful.
Please subscribe to receive notifications on latest updates.