Description
Jesse Seldess (jseldess) commented:
On Slack, @darinpp mentioned:
Hi Jesse. I was just looking at this https://www.cockroachlabs.com/docs/stable/insert.html and it doesn't seem to be showing the insert into ... values(...) syntax in the BNF diagram. Am I missing something? For Postgress for example - https://www.postgresql.org/docs/11/sql-insert.html - they show first the default values (which we have), then values (which I can't see) and then the query.
I think the diagram using select_stmt
to represent various types of “selection clauses", including VALUES
. The link to https://www.cockroachlabs.com/docs/stable/selection-queries.html in the select_stmt
parameter description suggests as much.
However, I very much agree with @darinpp that the diagram isn't friendly or intuitive. It should help users understand the statement syntax, as they most often use it, without having to dig deep and bounce around. We should revisit this and find a way to make the diagram express the most common cases, including VALUES
.
cc: @knz, who was involved in the way we documented "selection clauses". @rmloveland, @ericharmeling, not sure which of you wants to take this. Not sure if this is p1 or p2.
Jira Issue: DOC-322