phalcon/cphalcon · error · Phalcon\Mvc\Model\Exceptions\ColumnNotInTableMap

Column '{column}' isn't part of the column map in '{classNam

Error message

Column '{column}' isn't part of the column map in '{className}'

What it means

Error "Column '{column}' isn't part of the column map in '{className}'" thrown in phalcon/cphalcon.

Source

Thrown at phalcon/Mvc/Model.zep:1566

        /**
         * Create a condition from the primary keys
         */
        for primaryKey in primaryKeys {
            /**
             * Every column part of the primary key must be in the bind data
             * types
             */
            if unlikely !fetch bindType, bindDataTypes[primaryKey] {
                throw new BindTypeNotDefined(primaryKey, get_class(this));
            }

            /**
             * Take the column values based on the column map if any
             */
            if typeof columnMap == "array" {
                if unlikely !fetch attributeField, columnMap[primaryKey] {
                    throw new ColumnNotInTableMap(primaryKey, get_class(this));
                }
            } else {
                let attributeField = primaryKey;
            }

            /**
             * If the attribute is currently set in the object add it to the
             * conditions
             */
            if unlikely !fetch value, this->{attributeField} {
                throw new PrimaryKeyAttributeNotSet(attributeField, get_class(this));
            }

            /**
             * Escape the column identifier
             */
            let values[] = value,
                conditions[] = writeConnection->escapeIdentifier(primaryKey) . " = ?",

View on GitHub (pinned to b7419de9cd)

When it happens

Trigger: Thrown at phalcon/Mvc/Model.zep:1566 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of phalcon/cphalcon@b7419de9cd (2026-08-21). Data as JSON: /api/errors/0792441065cbcbdf. Report an issue: GitHub.