正式发布前:2024-07-17
runSql("CREATE VIEW AlbertaAddresses AS SELECT * FROM sakila.address WHERE district = 'Alberta'");
//check TABLES for successful CREATE VIEW
runSql("SHOW TABLES LIKE 'AlbertaAddresses' ", function (ResultSetData) {
print(ResultSetData);
});
输出为
[ { "Tables_in_sakila (AlbertaAddresses)": "albertaaddresses" } ]
runSql("DROP VIEW IF EXISTS albertaaddresses");
//check TABLES for successful DROP VIEW
runSql("SHOW TABLES LIKE 'A%' ", function (IResultSetData) {
print(IResultSetData);
});
输出为
[ { "Tables_in_sakila (A%)": "actor" }, { "Tables_in_sakila (A%)": "actor_info" }, { "Tables_in_sakila (A%)": "address" } ]