Discover create database if not exists, include the articles, news, trends, analysis and practical advice about create database if not exists on alibabacloud.com
1. Create a databaseHive>create database myhive;Hive>create database if not exists myhive;Hive>show databases;hive>show databases like ' *t* ';Description: Hive generated the corresponding directory (*.DB) for the database created, under the
This article aims at the MySQL database basic operation carries on the study research, needs to understand the friend not to miss this article.
The following are used on the command line under Windows 64-bit operating systems.
Before we learn, let'
Reprint Please specify source: https://blog.csdn.net/l1028386804/article/details/80173778I. Hive Overview 1, why hive is used
The birth of the Hadoop ecosystem brings dawn to efficient and fast processing of big data, but requires writing mapreduce
MySQL5.6 has many new features, many of whom are interested in the global transaction ordinal function (Gtids). The reason why everyone is interested in this feature is that it's always a hassle to reconnect from the server and a new primary server,
Database: A warehouse in which data is stored and managed according to data structures.MySQL is a relational database management systemAfter MySQL is installed ...MySQL Start-up1: Find MySQL Right-click on "Services" in the control Panel to start2:
I. Creating a database (default character set and collation) (1) Create a database[SQL]View PlainCopy
mysql> CREATE DATABASE my_db1;
Query OK, 1 row Affected (0.00 sec)
(2) Because MY_DB1 already exists, create an error
Database IntroductionA database (DATABASE,DB) is a collection of organized, shareable data that is stored in a computer for a long period of time. The data in the database is organized, described and stored in a certain mathematical model, with
MYSQL.CNF add[Mysqld]Character-set-server=utf8Collation-server=utf8_general_ci[Client]Default-character-set=utf8[MySQL]Default-character-set=utf8drop database user;CREATE DATABASE IF not EXISTS user character set UTF8;CREATE DATABASE IF not EXISTS
First, prepare the data# Create databases and tables under my MySQL and insert a few data mysql> CREATE database if not EXISTS student default character set UTF8 collate Utf8_gen Eral_ci; mysql> use student; Mysql> CREATE table if not exists
We can understand the rationale behind mysqldump by opening the general log and looking at the commands executed during mysqldump full library backup.Open General Logmysql> set global general_log=on;Where the general log's storage path can be viewed
SqlConcept: Structured Query Language (SQL = Structured query Language),is also a programming language (database query and programming language), can be used for data access and query, update, management of relational database systemPS: SQL between
The following are used on the command line under the Windows 64-bit operating system.Before studying, let's explain what some of the symbols in the MySQL syntax format mean:(1) The brackets ([]) indicate that they exist or do not exist, and are
For MySQL backup, it can be divided into the following two kinds:1. Cold Standby2. Hot standbyAmong them, cold, as the name implies, is to turn off the database, using operating system commands to copy database related files. The hot standby refers
Recently started to re-learn python, studying some of the Python operations MySQL database knowledge, recorded here, as a learning note,Basic Environment: Python 3.5.1MySQL version: 5.6.35 (RPM installation mode)Operating systems: Centos7.3 and
/*sql Multiline Comment */--SQL single line comment--Create User:CREATE user ' username ' [@ ' host name '] identified by ' password '--the hostname can be empty and the default is the% permission, which means all hosts can connect.CREATE USER '
How to use PHP to automate. sql files. In fact, it is very simple to get the contents of the SQL file and then execute each sentence of SQL statement at once.This is the codeRead file contents $_sql = file_get_contents (' Test.sql '); $_arr =
How to use PHP to automate. sql files. In fact, it is very simple to get the contents of the SQL file and then execute each sentence of SQL statement at once.This is the codeRead file contents $_sql = file_get_contents (' Test.sql '); $_arr =
Creating a Database
The simplest way:
Copy Code code as follows:
CREATE DATABASE my_db;
Or is:
Copy Code code as follows:
CREATE DATABASE IF not EXISTS my_db;
To create a UTF8-encoded database:
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.