{"record":{"id":"e6d61ba976c8e4a9","repo":"risingwavelabs/risingwave","slug":"view-has-no-fragments-to-describe","errorCode":null,"errorMessage":"view has no fragments to describe","messagePattern":"view has no fragments to describe","errorType":"error_code","errorClass":"ErrorCode::NotSupported","httpStatus":null,"severity":"error","filePath":"src/frontend/src/handler/describe.rs","lineNumber":304,"sourceCode":"                Relation::Source(s) => {\n                    if s.is_shared() {\n                        s.catalog.id.as_share_source_job_id()\n                    } else {\n                        bail!(ErrorCode::NotSupported(\n                            \"non shared source has no fragments to describe\".to_owned(),\n                            \"Use `DESCRIBE` instead of `DESCRIBE FRAGMENTS`\".to_owned(),\n                        ));\n                    }\n                }\n                Relation::BaseTable(t) => t.table_catalog.id.as_job_id(),\n                Relation::SystemTable(_t) => {\n                    bail!(ErrorCode::NotSupported(\n                        \"system table has no fragments to describe\".to_owned(),\n                        \"Use `DESCRIBE` instead of `DESCRIBE FRAGMENTS`\".to_owned(),\n                    ));\n                }\n                Relation::Share(_s) => {\n                    bail!(ErrorCode::NotSupported(\n                        \"view has no fragments to describe\".to_owned(),\n                        \"Use `DESCRIBE` instead of `DESCRIBE FRAGMENTS`\".to_owned(),\n                    ));\n                }\n                _ => {\n                    // Other relation types (Subquery, Join, etc.) are not directly describable.\n                    return Err(not_found_err.into());\n                }\n            }\n        } else if let Ok(sink) = binder.bind_sink_by_name(object_name.clone()) {\n            sink.sink_catalog.id.as_job_id()\n        } else {\n            return Err(not_found_err.into());\n        }\n    };\n\n    let meta_client = session.env().meta_client();\n    let fragments = &meta_client.list_table_fragments(&[job_id]).await?[&job_id];","sourceCodeStart":286,"sourceCodeEnd":322,"githubUrl":"https://github.com/risingwavelabs/risingwave/blob/6469eb736d691e8e9b8a419a57edd6429ca77417/src/frontend/src/handler/describe.rs#L286-L322","documentation":"Raised in handle_describe_fragments when the target relation has no streaming job to show: DESC/DESCRIBE FRAGMENTS was run on a relation without fragments (e.g., a system table or a non-shared source). It signals that fragment inspection is inapplicable to this object, not an internal failure.","triggerScenarios":"Running `DESCRIBE FRAGMENTS <view_name>` on a regular SQL VIEW created via `CREATE VIEW`.","commonSituations":"Assuming views have an execution graph; mistyping an MV name and hitting a plain view with the same/similar name.","solutions":["Use `DESCRIBE <view_name>` for schema inspection","Run `DESCRIBE FRAGMENTS` on the materialized view actually backing the workload","Use `EXPLAIN <query>` to see the logical plan of a view"],"exampleFix":"// before\nDESCRIBE FRAGMENTS my_view;\n// after\nDESCRIBE my_view;","handlingStrategy":"validation","validationCode":"-- views have no streaming job; check object type first\nSELECT * FROM rw_catalog.rw_views WHERE name = 'my_view';","typeGuard":null,"tryCatchPattern":"catch NotSupported and fall back to DESCRIBE or EXPLAIN","preventionTips":["Verify the target is an MV (`SHOW MATERIALIZED VIEWS`) before DESCRIBE FRAGMENTS","Remember views are logical only — they have no fragments"],"tags":["sql","view","fragments"],"backgroundTag":"unsupported-operation","analyzedSha":"6469eb736d691e8e9b8a419a57edd6429ca77417","analyzedAt":"2026-09-11T21:06:21.487Z","contentChangedAt":"2026-09-11T21:06:21.487Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}