2020-07-11 11:05:49 +00:00
|
|
|
|
---
|
2022-04-09 13:29:05 +00:00
|
|
|
|
sidebar_position: 53
|
|
|
|
|
sidebar_label: USE
|
2020-07-11 11:05:49 +00:00
|
|
|
|
---
|
|
|
|
|
|
2022-06-02 10:55:18 +00:00
|
|
|
|
# USE Statement
|
2020-07-11 11:05:49 +00:00
|
|
|
|
|
|
|
|
|
``` sql
|
|
|
|
|
USE db
|
|
|
|
|
```
|
|
|
|
|
|
2022-01-28 22:09:46 +00:00
|
|
|
|
Lets you set the current database for the session.
|
2020-07-11 11:05:49 +00:00
|
|
|
|
|
2022-01-28 22:09:46 +00:00
|
|
|
|
The current database is used for searching for tables if the database is not explicitly defined in the query with a dot before the table name.
|
2020-07-11 11:05:49 +00:00
|
|
|
|
|
2022-01-28 22:09:46 +00:00
|
|
|
|
This query can’t be made when using the HTTP protocol, since there is no concept of a session.
|