apache/cassandra · error · InvalidRequestException
Column deletion is not supported by table
Error message
Column deletion is not supported by table %s
What it means
AbstractMutableVirtualTable is the base class for writable virtual tables. Mutations are dispatched to overridable apply* hooks; applyColumnDeletion is the hook invoked when an UPDATE/DELETE removes a column value. Unless a subclass overrides it, the base implementation rejects the operation with this InvalidRequestException, so the virtual table never supports cell-level deletes by default.
Solutions
- Remove the column deletion from the statement; delete the whole row instead (DELETE FROM table WHERE pk...) if the table supports row deletion.
- Use an UPDATE that sets the column to an appropriate value rather than nulling it.
- If you own the virtual table implementation, override applyColumnDeletion to persist the deletion semantics you need.
- Check the table's documentation/description (DESCRIBE / system_views.tables) for which mutations are supported.
Example fix
// before DELETE cache_hit_count FROM system_views.client_request_metrics_latency; // not supported // after UPDATE system_views.client_request_metrics_latency SET cache_hit_count = 0 WHERE ...; // or override applyColumnDeletion in the virtual table class
Defensive patterns
Strategy: validation
Validate before calling
// Check the table's supported mutations before issuing a column delete
VirtualTable vt = VirtualKeyspaceRegistry.instance.getTableMetadata(tableId) != null ? ... : null;
boolean supports = vt instanceof AbstractMutableVirtualTable
&& ((AbstractMutableVirtualTable) vt).overridesApplyColumnDeletion(); // or consult table docs Try / catch
try { session.execute("DELETE col FROM vtable WHERE pk = ?", pk); }
catch (InvalidRequestException e) { if (e.getMessage().contains("Column deletion is not supported")) { /* fall back to row delete or UPDATE */ } else throw e; } Prevention
- Never assume virtual tables accept cell-level deletes; check per-table mutation support.
- Prefer whole-row deletes or UPDATEs on virtual tables.
- Document mutation capabilities of any custom virtual table subclass.
When it happens
Trigger: A CQL DELETE of a specific column (or UPDATE setting a column to null) against a virtual table whose class does not override applyColumnDeletion, routed through apply() -> applyColumnDeletion(partitionKey, clusteringColumns, columnName).
Common situations: Users attempt cell-level deletes on system virtual tables (e.g. in system_views/system) that only implement full-row deletes or updates; tooling that blindly generates `DELETE col FROM virtual_table ...` statements.
Understand the failure class
Background: UnsupportedOperationException and "is not supported" errors: when a library deliberately refuses a call — this error's family across 30 libraries.
Related errors
- Can only unset '" + name + "'
- Cannot filter this table by partial partition key
- Cannot update '" + name + "'
- Column modification is not supported by table
- May only delete on txn_id and id_micros
AI-assisted analysis of apache/cassandra@88fd0f6a0e (2026-09-10).
Data as JSON: /api/errors/fbabeb4ad8d8e37a.
Report an issue: GitHub.
Appendix: source
Thrown at src/java/org/apache/cassandra/db/virtual/AbstractMutableVirtualTable.java:155
private static BoundType boundType(ClusteringBound<?> bound)
{
return bound.isInclusive() ? BoundType.CLOSED : BoundType.OPEN;
}
protected void applyRangeTombstone(ColumnValues partitionKey, Range<ColumnValues> range)
{
throw invalidRequest("Range deletion is not supported by table %s", metadata);
}
protected void applyRowDeletion(ColumnValues partitionKey, ColumnValues clusteringColumns)
{
throw invalidRequest("Row deletion is not supported by table %s", metadata);
}
protected void applyColumnDeletion(ColumnValues partitionKey, ColumnValues clusteringColumns, String columnName)
{
throw invalidRequest("Column deletion is not supported by table %s", metadata);
}
protected void applyColumnUpdate(ColumnValues partitionKey,
ColumnValues clusteringColumns,
Optional<ColumnValue> columnValue)
{
throw invalidRequest("Column modification is not supported by table %s", metadata);
}
private static String columnName(Cell<?> cell)
{
return cell.column().name.toCQLString();
}
/**
* A set of partition key or clustering column values.
*/
public static final class ColumnValues implements Comparable<ColumnValues>View on GitHub (pinned to 88fd0f6a0e)