SigNoz/signoz · warning · model.ApiError
removing a selected field is not allowed, please reach out t
Error message
removing a selected field is not allowed, please reach out to support.
What it means
UpdateLogField refuses requests where field.Selected is false — once a log field column has been materialized/selected in ClickHouse, unselecting it via the API is not allowed and requires support intervention.
Source
Thrown at pkg/query-service/app/clickhouseReader/reader.go:2691
if overrideFieldType != "" {
field.Type = overrideFieldType
}
// all static fields are assumed to be selected as we don't allow changing them
if isColumn(tableStatement, field.Type, field.Name, field.DataType) {
response.Selected = append(response.Selected, field)
} else {
response.Interesting = append(response.Interesting, field)
}
}
}
func (r *ClickHouseReader) UpdateLogField(ctx context.Context, field *model.UpdateField) *model.ApiError {
ctx = ctxtypes.NewContextWithCommentVals(ctx, map[string]string{
instrumentationtypes.CodeNamespace: "clickhouse-reader",
instrumentationtypes.CodeFunctionName: "UpdateLogField",
})
if !field.Selected {
return model.ForbiddenError(errors.New("removing a selected field is not allowed, please reach out to support."))
}
colname := utils.GetClickhouseColumnNameV2(field.Type, field.DataType, field.Name)
field.DataType = strings.ToLower(field.DataType)
dataType := constants.MaterializedDataTypeMap[field.DataType]
chDataType := constants.ChDataTypeMap[field.DataType]
attrColName := fmt.Sprintf("%s_%s", field.Type, dataType)
for _, table := range []string{r.logsLocalTableV2, r.logsTableV2} {
q := "ALTER TABLE %s.%s ON CLUSTER %s ADD COLUMN IF NOT EXISTS `%s` %s DEFAULT %s['%s'] CODEC(ZSTD(1))"
query := fmt.Sprintf(q,
r.logsDB, table,
r.cluster,
colname, chDataType,
attrColName,
field.Name,
)View on GitHub (pinned to 5069bf80b0)
Solutions
- Reach out to support to unselect/materialize-column removal for log fields
- Instead of unselecting, adjust which fields you select going forward and stop adding new ones
- Review selected fields carefully before enabling them, since the operation is effectively irreversible via API
Example fix
// before
{"type":"log","name":"user.id","dataType":"string","selected":false}
// after
// (no API fix — contact support; avoid unselecting already-selected fields) Defensive patterns
Strategy: type-guard
Validate before calling
if !field.Selected && wasPreviouslySelected(field) {
return errors.New("unsupported", "unselecting selected fields requires support")
} Type guard
func isUnselectRequest(f *model.UpdateField) bool { return f != nil && !f.Selected } Try / catch
if apiErr := updateLogField(ctx, field); apiErr != nil && apiErr.IsForbidden() {
// surface 'contact support' message
} Prevention
- Treat field selection as irreversible; review before enabling
- Track materialized fields in IaC so accidental selections are caught in review
When it happens
Trigger: PUT/PATCH to the update-log-field endpoint with {"selected": false} in the body.
Common situations: Users trying to reduce cardinally materialized columns from the UI; cleanup attempts after accidentally selecting too many fields.
Related errors
- error while fetching logs schema: %s
- no operations table supplied
- no index table supplied
- couldn't get attribute keys: %w
- couldn't query attrib values for suggestions: %w
AI-assisted analysis of SigNoz/signoz@5069bf80b0 (2026-08-28).
Data as JSON: /api/errors/a8192068983dd7f6.
Report an issue: GitHub.