{"record":{"id":"f92321c65bbd391d","repo":"prestodb/presto","slug":"unsupported-frame-start-type","errorCode":null,"errorMessage":"Unsupported frame start type: ","messagePattern":"Unsupported frame start type: ","errorType":"exception","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"presto-main-base/src/main/java/com/facebook/presto/operator/window/WindowPartition.java","lineNumber":372,"sourceCode":"        // 2. non-null value in current row. Find frame boundaries starting from recentRange\n        int frameStart;\n        switch (frameInfo.getStartType()) {\n            case UNBOUNDED_PRECEDING:\n                frameStart = 0;\n                break;\n            case CURRENT_ROW:\n                frameStart = peerGroupStart - partitionStart;\n                break;\n            case PRECEDING:\n                frameStart = getFrameStartPreceding(recentRange.getStart(), frameInfo, startComparator);\n                break;\n            case FOLLOWING:\n                // note: this is the only case where frameStart might get out of partition bound\n                frameStart = getFrameStartFollowing(recentRange.getStart(), frameInfo, startComparator);\n                break;\n            default:\n                // start type cannot be UNBOUNDED_FOLLOWING\n                throw new IllegalArgumentException(\"Unsupported frame start type: \" + frameInfo.getStartType());\n        }\n\n        int frameEnd;\n        switch (frameInfo.getEndType()) {\n            case UNBOUNDED_FOLLOWING:\n                frameEnd = partitionEnd - partitionStart - 1;\n                break;\n            case CURRENT_ROW:\n                frameEnd = peerGroupEnd - partitionStart - 1;\n                break;\n            case PRECEDING:\n                // note: this is the only case where frameEnd might get out of partition bound\n                frameEnd = getFrameEndPreceding(recentRange.getEnd(), frameInfo, endComparator);\n                break;\n            case FOLLOWING:\n                frameEnd = getFrameEndFollowing(recentRange.getEnd(), frameInfo, endComparator);\n                break;\n            default:","sourceCodeStart":354,"sourceCodeEnd":390,"githubUrl":"https://github.com/prestodb/presto/blob/55bb57d202de3b926896fa966c2c4a44c779634e/presto-main-base/src/main/java/com/facebook/presto/operator/window/WindowPartition.java#L354-L390","documentation":"When computing a RANGE frame's start boundary, getFrameRange switches on the frame start type (UNBOUNDED_PRECEDING, PRECEDING, CURRENT_ROW, FOLLOWING). The default branch throws because UNBOUNDED_FOLLOWING is illegal as a frame start; reaching it means an invalid FrameInfo slipped through analysis.","triggerScenarios":"A FrameInfo with startType UNBOUNDED_FOLLOWING or an unknown start type reaching the window operator — normally prevented by SQL grammar; possible only via internal bugs or custom FrameInfo construction.","commonSituations":"Presto internal inconsistencies between frame analysis and execution; custom plugins building FrameInfo manually.","solutions":["Use only valid frame starts in OVER clauses: UNBOUNDED PRECEDING, <n> PRECEDING, CURRENT ROW, or <n> FOLLOWING.","If constructing FrameInfo in custom code, validate startType != UNBOUNDED_FOLLOWING before execution.","Report as a planner bug if reproducible from ordinary SQL."],"exampleFix":null,"handlingStrategy":"validation","validationCode":"-- valid frame starts only: UNBOUNDED PRECEDING, <n> PRECEDING, CURRENT ROW, <n> FOLLOWING\nSELECT sum(x) OVER (ORDER BY t ROWS BETWEEN UNBOUNDED PRECEDING AND CURRENT ROW) FROM tab;","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Never specify UNBOUNDED FOLLOWING as a frame start.","Review window frame syntax against SQL standard before deploying.","Keep all nodes on the same Presto version."],"tags":["window-function","internal-error","frame"],"backgroundTag":"unsupported-frame-type","analyzedSha":"55bb57d202de3b926896fa966c2c4a44c779634e","analyzedAt":"2026-09-04T12:50:26.162Z","contentChangedAt":"2026-09-04T12:50:26.162Z","schemaVersion":2},"datasetVersion":"2026-09-11T21:17:09.523Z"}