{"record":{"id":"e60e1f73013178fe","repo":"hasura/graphql-engine","slug":"field-mapping-field-name-not-found-for-object-ty","errorCode":null,"errorMessage":"Field mapping {field_name} not found for object type {object_type_name}","messagePattern":"Field mapping (.+?) not found for object type (.+?)","errorType":"error_code","errorClass":"MapFieldNamesError","httpStatus":null,"severity":"error","filePath":"v3/crates/plan/src/query/arguments.rs","lineNumber":657,"sourceCode":"\n    Ok(resolved_arguments)\n}\n\n#[derive(Debug, thiserror::Error)]\npub enum MapFieldNamesError {\n    #[error(\"Value did not match array type, was expecting {expected_type}\")]\n    ExpectedAnArray {\n        expected_type: QualifiedTypeReference,\n    },\n    #[error(\"Value did not match object type, was expecting {expected_type}\")]\n    ExpectedAnObject {\n        expected_type: QualifiedTypeReference,\n    },\n    #[error(\"Type mappings not found for object type {object_type_name}\")]\n    TypeMappingsNotFound {\n        object_type_name: Qualified<CustomTypeName>,\n    },\n    #[error(\"Field mapping {field_name} not found for object type {object_type_name}\")]\n    FieldMappingNotFound {\n        object_type_name: Qualified<CustomTypeName>,\n        field_name: FieldName,\n    },\n    #[error(\"Unknown fields found in object type {object_type_name}: {fields:?}\")]\n    UnknownFieldsInObject {\n        object_type_name: Qualified<CustomTypeName>,\n        fields: Vec<String>,\n    },\n}\n\nimpl TraceableError for MapFieldNamesError {\n    fn visibility(&self) -> ErrorVisibility {\n        match self {\n            Self::ExpectedAnArray { .. }\n            | Self::ExpectedAnObject { .. }\n            | Self::UnknownFieldsInObject { .. } => ErrorVisibility::User,\n            Self::TypeMappingsNotFound { .. } | Self::FieldMappingNotFound { .. } => {","sourceCodeStart":639,"sourceCodeEnd":675,"githubUrl":"https://github.com/hasura/graphql-engine/blob/724551b9ae87845594ef0408cff0e50eb6c90dc5/v3/crates/plan/src/query/arguments.rs#L639-L675","documentation":"MapFieldNamesError::FieldMappingNotFound indicates the object's type mapping exists, but the value contains a field for which no field mapping entry exists in the data connector's type mapping for that object type. The planner cannot translate the client-side field name to the connector's column/field name.","triggerScenarios":"Passing an argument object containing a field that is not present in the type_mapping's field_mappings for the object, e.g. {\"emial\": ...} (typo) or a field that exists in metadata but not in the connector schema.","commonSituations":"Typos in field names inside nested argument objects; schema drift after a column rename; computed/derived fields exposed in metadata that lack backing mappings; stale client models after backend schema changes.","solutions":["Correct the field name to match the mapped field exactly (case-sensitive)","Inspect the type mapping's field_mappings for the object and remove or rename the offending key","Regenerate client types / reload metadata after the connector schema changes","If the field should exist, add the missing field mapping to the source's schema"],"exampleFix":"// before\n{ \"where\": { \"emial\": { \"_eq\": \"a@b.c\" } } }\n// after\n{ \"where\": { \"email\": { \"_eq\": \"a@b.c\" } } }","handlingStrategy":"validation","validationCode":"let known: HashSet<_> = mapping.field_mappings.keys().collect();\nfor k in value.keys() { assert!(known.contains(k), \"unknown field {k}\"); }","typeGuard":"const hasFieldMapping = (m: FieldMappings, f: string): boolean => Object.prototype.hasOwnProperty.call(m, f);","tryCatchPattern":"Catch FieldMappingNotFound and return a precise 'unknown field X on type Y' message to the caller.","preventionTips":["Use codegen so field names come from the schema","Lint for typos in nested filters/where objects","Regenerate clients after column renames"],"tags":["rust","ndc","field-mapping","schema-mismatch","arguments"],"backgroundTag":"schema-validation-failed","analyzedSha":"724551b9ae87845594ef0408cff0e50eb6c90dc5","analyzedAt":"2026-08-28T07:32:55.105Z","schemaVersion":2},"datasetVersion":"2026-08-28T11:17:15.048Z"}