Skip to content

[fix](doc) SHOW-PARTITION.md en: mark example output illustrative, align fence with zh#3813

Open
boluor wants to merge 1 commit into
apache:masterfrom
boluor:fix/show-partition-en-illustrative
Open

[fix](doc) SHOW-PARTITION.md en: mark example output illustrative, align fence with zh#3813
boluor wants to merge 1 commit into
apache:masterfrom
boluor:fix/show-partition-en-illustrative

Conversation

@boluor
Copy link
Copy Markdown
Contributor

@boluor boluor commented May 26, 2026

Summary

Doc page (4.x): `sql-statements/table-and-view/table/SHOW-PARTITION.md` (EN).

The example uses a hard-coded partition ID `13004` and shows a 1-row sample output as if it were the literal expected result. On any fresh cluster (e.g. our Apache Doris 4.1.1 verification rig) that partition does not exist, so the actual output is an empty result set. The doc was internally over-promising. ZH already fenced the same result as ````sql````, which renders the same and signals "look-like" rather than "literal expected".

Two adjustments to EN:

  • Replace the bare "Results:" lead-in with a one-paragraph note that calls out `13004` is illustrative (point at `SHOW PARTITIONS`) and that the function returns an empty set if no partition matches.
  • Align the fence to ````sql```` matching ZH, so the verifier doesn't try to strict-compare the illustrative row.

Verification

On a single-node Apache Doris 4.1.1 cluster:

```
mysql> SHOW PARTITION 13004;
Empty set (0.01 sec)
```

A longer-term fix would be to add a setup block that creates a table, calls `SHOW PARTITIONS` to capture a real partition ID, and then uses that ID in `SHOW PARTITION`. That is a much bigger restructure; this PR is the minimum honest fix.

Test plan

  • Run `SHOW PARTITION 13004` on a 4.1.1 cluster — 0 rows.
  • Prose accurately describes the actual behavior for both "partition exists" and "does not exist" cases.
  • No content lost; sample output table preserved unchanged.

🤖 Generated with Claude Code

…ign with zh fence

The example uses a hard-coded partition ID `13004` that does not exist
on any fresh cluster, so running the snippet returns an empty result
set — but the EN page presented its sample 1-row table as the literal
expected output (fenced `text`), implying it is reproducible. ZH page
already fenced the same result as `sql`, which renders the same in
docs but signals "look-like" rather than "literal expected".

Update EN to:
- Replace "Results:" with prose that calls out that `13004` is
  illustrative and you must substitute your own partition ID (point
  at `SHOW PARTITIONS`), and that the function returns an empty set
  if no partition matches.
- Align the fence to ```` ```sql ```` matching ZH.

Verified on a single-node Apache Doris 4.1.1 cluster: `SHOW PARTITION
13004` returns 0 rows, no error.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant