Cockroach: inconsistent display of table name with EXPLAIN and EXPLAIN ANALYZE

Created on 6 Nov 2020  ·  6Comments  ·  Source: cockroachdb/cockroach

Describe the problem

Inconsistent display of table name with EXPLAIN and EXPLAIN ANALYZE

To Reproduce

CREATE TABLE authors (
    id INT PRIMARY KEY, 
    name STRING);

INSERT INTO authors VALUES (1, 'Toni Morrison'),
                           (2, 'James Tiptree'),
                           (3, 'Richard Wright');

root@:26257/movr> EXPLAIN SELECT name FROM authors WHERE id=2;
    tree    |    field    |   description
------------+-------------+------------------
            | distributed | false
            | vectorized  | false
  render    |             |
   └── scan |             |
            | table       | authors@primary
            | spans       | /2-/2/#
(6 rows)

Time: 895.2µs

root@:26257/movr> EXPLAIN ANALYZE SELECT name FROM authors WHERE id=2;
  automatic |

                                                                         url
------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
    false   | https://cockroachdb.github.io/distsqlplan/decode.html#eJyMkE9Lw0AQxe9-imG8KKymCSqyILRqxEBsa1LwHzlss0MNJNm4s0FLyXeXJIp4EDzOm_fe_nZ2yG8lSgwfl_EsmsNsPoufnkM4uI7SVXofH0IaxuHVCmpVEdwkiztQrXs1luHhNkxCKDRcQIACa6NpripilC_oYyawsSYnZmN7aTcYIv2BciKwqJvW9XImMDeWUO7QFa4klLhS65ISUpqsN0GBmpwqyqG2sUWl7Hb6hYAC00bVLMELjrzA20eBi9ZJmPZA1rwzWFJago8C2amyBFdUJME_Pjs9r_r8euvo23USwCVmnUDTuh88dmpDKP1O_P8LCXFjaqZf9H81T7pMIOkNjWdi09qcltbkwzPjuBhyg6CJ3bj1xyGqx1WXdXufAQAA__9N75LN
(1 row)

Time: 3.267ms

authors@primary

vs

primary@authors

image

Expected behavior

Table name displayed consistently

Environment:

  • CockroachDB version v20.1.6
  • Server OS: Linux
  • Client app [e.g. cockroach sql
C-bug O-community X-blathers-triaged

All 6 comments

Hello, I am Blathers. I am here to help you get the issue triaged.

Hoot - a bug! Though bugs are the bane of my existence, rest assured the wretched thing will get the best of care here.

I have CC'd a few people who may be able to assist you:

  • @asubiotto (found keywords: vectorize)

If we have not gotten back to your issue within a few business days, you can try the following:

  • Join our community slack channel and ask on #cockroachdb.
  • Try find someone from here if you know they worked closely on the area and CC them.

:owl: Hoot! I am a Blathers, a bot for CockroachDB. My owner is otan.

I think we should change the distsql diagram to read authors@primary.

Thanks for the feedback. This is timely as we are updating our representation of EXPLAIN ANALYZE cc @RaduBerinde @Annebirzin

We have actually already fixed this inconsistency on 20.2 branch (#52085), so I'll close this issue.

I'll backport that PR to 20.1 branch.

@gliptak Thank you for contributing to CockroachDB this year. As a token of our appreciation we would like to send you a gift. Please DM me on our community Slack @lisa so I can send you a link. (If you don’t want a gift, we also have a charitable contribution choice.) All orders need to be in by December 13, so please send this asap. :)

Was this page helpful?
0 / 5 - 0 ratings