User Tools

Site Tools

A PCRE internal error occured. This might be caused by a faulty plugin

Sidebar

**HPL/SQL is included to Apache Hive since version 2.0** * [[home|Home]]\\ * [[why|Why HPL/SQL]]\\ * [[features|Key Features]]\\ * [[start|Get Started]]\\ * [[doc|HPL/SQL Reference]]\\ * [[download|Download]]\\ * [[new|What's New]]\\ * [[about|About]]

create-database

====== CREATE DATABASE Statement ====== CREATE DATABASE statement allows you to create a database. **Syntax**: <code language=sql> CREATE DATABASE | SCHEMA [IF NOT EXISTS] dbname_expr [COMMENT comment_expr] [LOCATION path_expr] </code> **Example**: Create a database named //testYYYYMMDD// (current date): <code language=sql> create database 'test' || replace(current_date, '-', ''); </code> **Compatibility:** MySQL, MariaDB, Hive **Version:** HPL/SQL 0.3.17 See also: * [[drop-database|DROP DATABASE]] * [[use|USE]]