# ColumnStore Rename Table

The `RENAME TABLE` statement renames one or more ColumnStore tables.

Notes:

* You cannot currently use `RENAME TABLE` to move a table from one database to another.
* See the `ALTER TABLE` syntax for an alternative to `RENAME Table`. The following statement renames the orders table:

```sql
RENAME TABLE orders TO customer_order;
```

The following statement renames both the *orders* table and *customer* table:

```sql
RENAME TABLE orders TO customer_orders,customer TO customers;
```

You may also use `RENAME TABLE` to swap tables. This example swaps the *customer* and *vendor* tables (assuming the *`temp_table`*\
does not already exist):

```sql
RENAME TABLE customer TO temp_table, vendor TO customer,temp_table to vendor;
```

<sub>*This page is: Copyright © 2025 MariaDB. All rights reserved.*</sub>

{% @marketo/form formId="4316" %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://mariadb.com/docs/analytics/mariadb-columnstore/reference/5573.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
