Syntax
SHOW DATABASES LIKE '{regular_expression}'
Example
SHOW DATABASES LIKE 'test*';
Above snippet print all the databases that starts with the string ‘test’.
hive> SHOW DATABASES; OK bigdatademo default testdb1 testdb2 Time taken: 0.011 seconds, Fetched: 4 row(s) hive> ; hive> ; hive> SHOW DATABASES LIKE 'test*'; OK testdb1 testdb2 Time taken: 0.036 seconds, Fetched: 2 row(s) hive>
No comments:
Post a Comment