db.properties怎么创建

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了db.properties怎么创建相关的知识,希望对你有一定的参考价值。

解决办法:1.创建数据库
hive>create database myhive;
hive>create database if not exists myhive;
2.查询数据库和表
hive>show databases;
hive>show tables;
使用正则表达式:
hive>show databases like 'h.*';

3.修改数据库默认位置
hive>create database myhive
>location 'my/myhive.db'; //要指定数据库名
1)为数据库增加描述信息
hive>create database myhive
>comment 'this is my';
hive> desc database myhive; //显示详细信息

2)增加一些和其相关的键-值对属性信息
hive>create database myhive
>with dbproperties('name'='lu','data'='2012-01-02');
查看:hive>desc database extended myhive;
hive>use default;
参考技术A 1.
创建properties文件
eclipse方法: 打开file--new--other 选择general--file--next 在file name后输...
新建普通的文本文件,然后修改后缀为properties即可创建。
2.
properties 文件
properties 文件就是文本文件,创建一个文本文件再改名就好了。

以上是关于db.properties怎么创建的主要内容,如果未能解决你的问题,请参考以下文章

db.properties 在Java中又啥作用

如何在activiti 5.14中更改db.properties

如何在spring中读取properties配置文件里面的信息

5.1properties属性

Tomcat 中 db.properties 无法找到

db.properties类中读写