{"record":{"id":"f50a3f8bf80b4544","repo":"OrchardCMS/OrchardCore","slug":"the-type-type-is-not-support-by-azure-ai-search","errorCode":null,"errorMessage":"The type '{type}' is not support by Azure AI Search","messagePattern":"The type '(.+?)' is not support by Azure AI Search","errorType":"exception","errorClass":"ArgumentOutOfRangeException","httpStatus":null,"severity":"error","filePath":"src/OrchardCore/OrchardCore.AzureAI.Core/Services/AzureAISearchIndexManager.cs","lineNumber":460,"sourceCode":"            IsFilterable = indexMap.IsFilterable,\n            IsSortable = indexMap.IsSortable,\n            IsHidden = indexMap.IsHidden,\n            IsFacetable = indexMap.IsFacetable,\n        };\n    }\n\n    private static SearchFieldDataType GetFieldType(Types type)\n        => type switch\n        {\n            Types.Boolean => SearchFieldDataType.Boolean,\n            Types.DateTime => SearchFieldDataType.DateTimeOffset,\n            Types.Number => SearchFieldDataType.Double,\n            Types.Integer => SearchFieldDataType.Int64,\n            Types.GeoPoint => SearchFieldDataType.GeographyPoint,\n            Types.Text => SearchFieldDataType.String,\n            Types.Complex => SearchFieldDataType.Complex,\n            Types.Vector => SearchFieldDataType.Single,\n            _ => throw new ArgumentOutOfRangeException(nameof(type), $\"The type '{type}' is not support by Azure AI Search\")\n        };\n}\n","sourceCodeStart":442,"sourceCodeEnd":463,"githubUrl":"https://github.com/OrchardCMS/OrchardCore/blob/4306c0717fe573f6fca1b4955909ddab6a192807/src/OrchardCore/OrchardCore.AzureAI.Core/Services/AzureAISearchIndexManager.cs#L442-L463","documentation":"GetFieldType maps Orchard's abstract index field types to Azure AI Search SearchFieldDataType values. An unrecognized type name hits the default arm and throws ArgumentOutOfRangeException, indicating the content field type is not supported by the Azure AI Search connector.","triggerScenarios":"Building index field definitions when an index mapping references a field type not in {Boolean, Number, Integer, GeoPoint, Text, Complex, Vector}.","commonSituations":"Custom content field types added by third-party modules being included in an AI Search index; typo'd type names in manually crafted index definitions; new Orchard field types not yet mapped by the connector.","solutions":["Remove the unsupported field from the index mappings or map it to a supported type","Add a custom mapping/converter for your field type before it reaches GetFieldType","Only include supported field types (Boolean, Number, Integer, GeoPoint, Text, Complex, Vector) in AI Search index profiles"],"exampleFix":"// before\n\"type\": \"Binary\"\n// after\n\"type\": \"Text\"","handlingStrategy":"validation","validationCode":"var supported = new[] { \"Boolean\",\"Number\",\"Integer\",\"GeoPoint\",\"Text\",\"Complex\",\"Vector\" }; var ok = supported.Contains(fieldType);","typeGuard":"bool isSupported = supportedTypes.Contains(fieldType, StringComparer.Ordinal);","tryCatchPattern":"try { fieldType = GetFieldType(type); } catch (ArgumentOutOfRangeException ex) when (ex.Message.Contains(\"not support\")) { /* exclude field or map to supported type */ }","preventionTips":["Only index fields with supported types in AI Search profiles","Add converters for custom field types before indexing","Review third-party module field types before including them"],"tags":["azure-ai-search","field-type","unsupported"],"backgroundTag":"unsupported-enum-value","analyzedSha":"4306c0717fe573f6fca1b4955909ddab6a192807","analyzedAt":"2026-09-13T17:41:05.024Z","contentChangedAt":"2026-09-13T17:41:05.024Z","schemaVersion":2},"datasetVersion":"2026-09-16T04:17:20.429Z"}