---
search:
  tags:
    - Data
    - PATCH
seo:
  description: >-
    Sets one column of one row and returns the row. You… Reference for the PATCH
    /_luna/tenants/{tenant}/data/{type}/{table}/{rowid} endpoint in the Luna
    API.
sidebar:
  label: Change a value in a row
  badge: PATCH
title: Change a value in a row
type: openapi-operation
---
Sets one column of one row and returns the row. You cannot change a row of an index.

`PATCH /_luna/tenants/{tenant}/data/{type}/{table}/{rowid}`

**Request body** (`application/json`, required)

- `key` (any, required) — The luna's key as JSON, such as \`{"id":"a"}\`. For a type keyed by one field, the value of that field alone also works.
- `column` (string, required) — The column to change.
- `value` (any) — The new value. Null when left out.

Request body example:

```json
{
  "key": null,
  "column": "string",
  "value": null
}
```

**Responses**

- `200` — The row as it is now.
- `default` — The request failed. The status says how and \`error.message\` says why.

Response example, 200:

```json
{
  "rowid": 0,
  "values": {}
}
```
