cockroachdb / cockroachdb/cockroach

ui: index view confused when index contains special whitespaces

Open
#94,334 0 comments 0 reactions 0 assignees View on GitHub
A-sql-observability A-webui-databases C-bug T-observability
Dominant language
Go
Stars
32.5k
Forks
4.1k
PR merge metrics
PR metrics pending

Description

**Describe the problem**

When an _index_ name contains special whitespace characters _which are allowed in PostgreSQL_, the index view in the DB console breaks down.

**To Reproduce**

1. run `cockroach demo --empty`
2. type in `CREATE TABLE t(x INT); CREATE INDEX "a`, press enter key
3. complete on a 2nd line: ` b" ON t(x);`
4. navigate to db console -> databases -> defaultdb -> table `t` -> index `a b`

See:
- the index definition is empty
- the index details are missing

**Expected behavior**

The db console should support special whitespace (including `\n`, `\f`, `\v`, `\t`) in index names without problem.

**Additional data / screenshots**
image

**Environment:**
- `master` branch towards v23.1

Epic: CRDB-20388

Jira issue: CRDB-22837

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.