{"record":{"id":"7e2fb501737eaf50","repo":"octobercms/october","slug":"the-database-column-name-cannot-be-empty","errorCode":null,"errorMessage":"The database column name cannot be empty.","messagePattern":"The database column name cannot be empty\\.","errorType":"exception","errorClass":"SystemException","httpStatus":null,"severity":"error","filePath":"modules/dashboard/classes/ReportDimension.php","lineNumber":116,"sourceCode":"     * @param string $databaseColumnName Specifies the column name in the data source table.\n     * Dimension columns typically match the primary key in the dimension table.\n     * @param string $displayName Specifies the dimension name used in reports, e.g., \"Product\".\n     * @param ?string $labelColumnName Specifies the name of the column for the dimension label.\n     * Use this column to provide a user-friendly label for the dimension, e.g., \"product_name\".\n     * If this argument is not provided, the value of $databaseColumnName is used as the dimension label.\n     */\n    public function __construct(\n        string $code,\n        string $databaseColumnName,\n        string $displayName,\n        ?string $labelColumnName = null\n    ) {\n        if (!strlen($code)) {\n            throw new SystemException('The dimension code cannot be empty.');\n        }\n\n        if (!strlen($databaseColumnName)) {\n            throw new SystemException('The database column name cannot be empty.');\n        }\n\n        if (!strlen($displayName)) {\n            throw new SystemException('The display name cannot be empty.');\n        }\n\n        $knownTypes = [\n            ReportDimension::TYPE_INDICATOR\n        ];\n\n        $dimensionType = null;\n        $codeParts = explode('@', $code);\n        if (count($codeParts) === 2) {\n            $dimensionType = $codeParts[0];\n        }\n\n        if ($dimensionType !== null && !in_array($dimensionType, $knownTypes)) {\n            throw new SystemException('Unknown dimension type: ' . $dimensionType);","sourceCodeStart":98,"sourceCodeEnd":134,"githubUrl":"https://github.com/octobercms/october/blob/b608633a7e8922487d91a8161499020121c3b3bf/modules/dashboard/classes/ReportDimension.php#L98-L134","documentation":"Error \"The database column name cannot be empty.\" thrown in octobercms/october.","triggerScenarios":"Thrown at modules/dashboard/classes/ReportDimension.php:116 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"b608633a7e8922487d91a8161499020121c3b3bf","analyzedAt":"2026-08-21T04:24:57.515Z","schemaVersion":2},"datasetVersion":"2026-08-21T11:28:35.574Z"}