Updated on 2025-03-24 GMT+08:00
Creating a Collection
This section describes how to create a collection on the DAS console.
Procedure
- Click
in the upper left corner and select a region and project. - Click
in the upper left corner, and under Databases, click Data Admin Service. - In the navigation pane on the left, choose Development Tool.
- Locate the DB instance that you want to log in to and click Log In in the Operation column.
- On the top menu bar, choose Database Management.
- On the Collections tab page, click New Collection.
- On the displayed page, enter a collection name. Select Capped collection, Auto index_id, and No padding as required.
- Capped collection: Set the maximum number of bytes and the maximum number of documents. If the specified value is reached, an error is reported. The value specified must be greater than 0.
- Auto index: Automatically create an index on the _id field.
- No padding: A storage policy that does not reserve storage space for the growth of a record when inserting it.
- Enter a validation rule and set Validation Level and Validation Action.
- Options for Validation Level include:
- strict: a strict validation level.
- moderate: a moderate validation level.
- off: no validation level.
- Options for Validation Action include:
- error
- warn
- Options for Validation Level include:
- Ensure that all the settings are correct and click OK. The collection you create appears in the collection list, and you can perform operations on it.
Parent topic: Collection Management
What is your overall rating for this page?
0
1
2
3
4
5
6
7
8
9
10
Very dissatisfiedVery satisfied
Thank you very much for your feedback. We will continue working to improve the documentation.
The system is busy. Please try again later.