> ## Documentation Index
> Fetch the complete documentation index at: https://gcore-doc-1046.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Sorted Set

### What is a Sorted Set?

A Sorted Set (ZSET) stores unique members, each associated with a numeric score. Members are ordered by score, which makes ZSETs ideal for leaderboards, rankings, and time- or priority-based lists.

You can add, update, or remove members while keeping the order automatically maintained.

* Each member is unique; adding the same member updates its score.
* Scores are numeric; members are ordered by score, then lexicographically for ties.
* Membership is stored in-memory with scores, so very large sets can impact memory usage.

## Creating a Sorted Set

1\. In the [Gcore Customer Portal](https://portal.gcore.com/accounts/reports/dashboard), navigate to **FastEdge** and choose the relevant page: **Edge Storage**.

2\. Find the Edge Storage you want to edit and click its name to open it.

3\. Click **Insert item** and select **Sorted Set**.

<Frame>
  <img src="https://mintcdn.com/gcore-doc-1046/NmzDUjLxfmvDFPXn/images/docs/fastedge/kv-stores/insert-zset.png?fit=max&auto=format&n=NmzDUjLxfmvDFPXn&q=85&s=73ae20d4e671e7f8f5bee30d121cf391" alt="FastEdge Insert Sorted Set" width="1255" height="776" data-path="images/docs/fastedge/kv-stores/insert-zset.png" />
</Frame>

4\. Give the Sorted Set a key, then click **Insert value**

<Frame>
  <img src="https://mintcdn.com/gcore-doc-1046/NmzDUjLxfmvDFPXn/images/docs/fastedge/kv-stores/create-zset.png?fit=max&auto=format&n=NmzDUjLxfmvDFPXn&q=85&s=7b886526f5974dcea14602f659df9349" alt="FastEdge Create Sorted Set" width="1251" height="807" data-path="images/docs/fastedge/kv-stores/create-zset.png" />
</Frame>

5\. Add as many rows as you would like, providing a score and the value. Values can be entered manually or uploaded from file.

<Frame>
  <img
    src="https://mintcdn.com/gcore-doc-1046/NmzDUjLxfmvDFPXn/images/docs/fastedge/kv-stores/insert-zset-values.png?fit=max&auto=format&n=NmzDUjLxfmvDFPXn&q=85&s=5d95f623bae0d053bd9d11c85c086e49"
    alt="FastEdge Insert Sorted Set
Values"
    width="842"
    height="319"
    data-path="images/docs/fastedge/kv-stores/insert-zset-values.png"
  />
</Frame>

Click **+ Add value** to get another entry row.

<Info>
  **Info**

  Uploading values from file has a 1 MB file size limit.

  **Note**:
  File uploads will transform the value in the UI Portal to a hash representation of its content.
</Info>

## Editing a Sorted Set

1\. In the [Gcore Customer Portal](https://portal.gcore.com/accounts/reports/dashboard), navigate to **FastEdge** and choose the relevant page: **Edge Storage**.

2\. Find the Edge Storage you want to edit and click its name to open it.

3\. Find the Sorted Set you want to edit, click the three-dot icon next to the key-value and select edit.

<Frame>
  <img
    src="https://mintcdn.com/gcore-doc-1046/NmzDUjLxfmvDFPXn/images/docs/fastedge/kv-stores/edit-zset-store.png?fit=max&auto=format&n=NmzDUjLxfmvDFPXn&q=85&s=171ec439115226d09128a28cf439e343"
    alt="FastEdge Edge Sorted Set
Edit"
    width="1257"
    height="773"
    data-path="images/docs/fastedge/kv-stores/edit-zset-store.png"
  />
</Frame>

4\. You are now able to add more values, edit existing values or delete values.

5\. If everything is configured correctly, click **Save Sorted Set** in the top right corner.

## Deleting a Sorted Set

1\. In the [Gcore Customer Portal](https://portal.gcore.com/accounts/reports/dashboard), navigate to **FastEdge** and choose the relevant page: **Edge Storage**.

2\. Find the Edge Storage you want to edit and click its name to open it.

3\. Find the Sorted Set you want to delete, click the three-dot icon next to the Sorted Set and select delete.

4\. Confirm you want to delete the entire Sorted Set.
