Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ui: fix creation index syntax on console #107170

Merged
merged 1 commit into from
Jul 19, 2023

Conversation

maryliag
Copy link
Contributor

@maryliag maryliag commented Jul 19, 2023

With an update to make the table name fully qualified, the index name was also using the fully qualified name, which contains ".", and that causes an invalid syntax since index name can't have periods.
Having the qualified name is not important for the index name itself, so this commit fixes by ignoring that part and using just the table name, how it was doing previously. It also fixes an invalid syntax when there were spaces on the name generate.

It also add a little more observability into indexes being created with STORING clause, adding that to the suffix of the index creation.

Fixes #107168

Before
Screenshot 2023-07-19 at 10 23 21 AM

After
https://www.loom.com/share/33da8b46fc9e4f72944c1d0ab943dea0

Release note (bug fix): Index recommendation on the UI no longer uses the full qualified name of a table to create an index name, allowing the creating of indexes directly from the Console to work.

@maryliag maryliag added the backport-23.1.x Flags PRs that need to be backported to 23.1 label Jul 19, 2023
@maryliag maryliag requested review from a team July 19, 2023 14:48
@cockroach-teamcity
Copy link
Member

This change is Reviewable

With an update to make the table name fully qualified,
the inedx name was also using the fully qualified name,
which contains ".", and that causes an invalid syntax
since index name can't have periods.
Having the qualified name is not important for the index
name itself, so this commit fixes by ignoring that part
and using just the table name, how it was doing previously.
It also fixes an invalid syntax when there were spaces on
the name generate.

It also add a little more observability into indexes
being created with STORING clause, adding that to the
suffix of the index creation.

Fixes cockroachdb#107168

Release note (bug fix): Index recommendation on the UI no
longer uses the full qualified name of a table to create an
index name, allowing the creating of indexes directly from
the Console to work.
@maryliag maryliag force-pushed the fix-debug-cluster-settings branch from 2f1fc87 to db4be30 Compare July 19, 2023 15:10
@maryliag
Copy link
Contributor Author

bors r+

@craig
Copy link
Contributor

craig bot commented Jul 19, 2023

This PR was included in a batch that timed out, it will be automatically retried

@craig
Copy link
Contributor

craig bot commented Jul 19, 2023

This PR was included in a batch that was canceled, it will be automatically retried

@craig
Copy link
Contributor

craig bot commented Jul 19, 2023

Build succeeded:

@craig craig bot merged commit e23993f into cockroachdb:master Jul 19, 2023
@maryliag maryliag deleted the fix-debug-cluster-settings branch July 19, 2023 23:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport-23.1.x Flags PRs that need to be backported to 23.1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

index recommendation using wrong syntax
3 participants