> For the complete documentation index, see [llms.txt](https://mariadb.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://mariadb.com/docs/analytics/mariadb-columnstore/reference/data-definition-statements/columnstore-create-view.md).

# ColumnStore CREATE VIEW

Creates a stored query in the MariaDB ColumnStore.

## Syntax

```bnf
CREATE
    [OR REPLACE]
    VIEW view_name [(column_list)]
    AS select_statement
```

## Notes

* If you describe a view in MariaDB ColumnStore, the column types reported may not match the actual column types in the underlying tables. This is normal and can be ignored.

The following statement creates a customer view of orders with status:

```sql
CREATE VIEW v_cust_orders (cust_name, order_number, order_status) AS
SELECT c.cust_name, o.ordernum, o.status FROM customer c, orders o
WHERE c.custnum = o.custnum;
```

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

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