# CREATE MILESTONE

> **📝 Note**: Prior to using this command, the `enable_bottomless` [engine variable](https://docs.singlestore.com/db/v9.1/reference/configuration-reference/engine-variables.md) must be set to `ON` (the default value).&#x20;

> **📝 Note**: This command is not available in all editions of SingleStore. For more information, see [SingleStore Editions](https://docs.singlestore.com/db/v9.1/introduction/singlestore-editions.md).

The `CREATE MILESTONE` command records a milestone, which is a named point to which you can restore an unlimited storage database. Restoring to the milestone will bring the database to the point in time when the milestone was created.

Following the execution of `CREATE MILESTONE`, the database can be restored at the milestone by running [DETACH DATABASE](https://docs.singlestore.com/db/v9.1/reference/sql-reference/data-definition-language-ddl/detach-database.md) and then [ATTACH DATABASE](https://docs.singlestore.com/db/v9.1/reference/sql-reference/data-definition-language-ddl/attach-database.md).

You must have `CREATE TABLE` permission in a database to create a milestone.

## Syntax

`CREATE MILESTONE [milestone_name] [FOR remote_database_name]`

## Arguments

## milestone\_name

A quoted string that is the name of the milestone to create.

## Remarks

* While the milestone is being created, SingleStore uploads the remote database's local cluster data to remote storage that has not yet been synced.
* If `milestone_name` is not specified, a name containing the current timestamp is automatically generated.
* If `milestone_name` already exists, the restore point used by the existing milestone is overwritten with the restore point of the new milestone.
* If `remote_database_name` is not specified, the context database (specified with the `USE` command) is used.
* Refer to the [Permissions Matrix](https://docs.singlestore.com/db/v9.1/reference/sql-reference/security-management-commands/permissions-matrix.md) for the required permissions.

## Example

The following example creates a new milestone on the existing unlimited storage database `bottomless_db`:

```
CREATE MILESTONE "m" FOR bottomless_db;
```

For a basic walkthrough of creating milestones, see [Attach an Unlimited Storage Database Using Point-in-Time Recovery (PITR)](https://docs.singlestore.com/db/v9.1/manage-data/unlimited-data-storage/attach-an-unlimited-storage-database-using-point-in-time-recovery-pitr.md).

***

Modified at: June 11, 2026

Source: [/db/v9.1/reference/sql-reference/data-definition-language-ddl/create-milestone/](https://docs.singlestore.com/db/v9.1/reference/sql-reference/data-definition-language-ddl/create-milestone/)

(An index of the documentation is available at /llms.txt)
