{"record":{"id":"98030caff53bd2e7","repo":"apache/cassandra","slug":"partitioner-s-for-table-s-in-keyspace-s-i","errorCode":null,"errorMessage":"Partitioner '%s' for table '%s' in keyspace '%s' is not supported.","messagePattern":"Partitioner '(.+?)' for table '(.+?)' in keyspace '(.+?)' is not supported\\.","errorType":"exception","errorClass":"InvalidRequestException","httpStatus":null,"severity":"error","filePath":"src/java/org/apache/cassandra/db/virtual/PartitionKeyStatsTable.java","lineNumber":169,"sourceCode":"    public UnfilteredPartitionIterator select(DecoratedKey partitionKey, ClusteringIndexFilter clusteringIndexFilter, ColumnFilter columnFilter, RowFilter rowFilter, DataLimits limits)\n    {\n        if (clusteringIndexFilter.isReversed())\n            throw new InvalidRequestException(REVERSED_QUERY_ERROR);\n\n        ByteBuffer[] key = ((CompositeType) this.metadata.partitionKeyType).split(partitionKey.getKey());\n        String keyspace = UTF8Type.instance.getString(key[0]);\n        String table = UTF8Type.instance.getString(key[1]);\n\n        KeyspaceMetadata ksm = Schema.instance.getKeyspaceMetadata(keyspace);\n        if (ksm == null)\n            throw invalidRequest(KEYSPACE_NOT_EXIST_ERROR, keyspace);\n\n        TableMetadata metadata = ksm.getTableOrViewNullable(table);\n        if (metadata == null)\n            throw invalidRequest(TABLE_NOT_EXIST_ERROR, table, keyspace);\n\n        if (!metadata.partitioner.supportsSplitting())\n            throw invalidRequest(PARTITIONER_NOT_SUPPORTED, metadata.partitioner.getClass().getName(), table, keyspace);\n\n        AbstractBounds<PartitionPosition> range = getBounds(metadata, clusteringIndexFilter, rowFilter);\n        return new SingletonUnfilteredPartitionIterator(select(partitionKey, metadata, clusteringIndexFilter, range));\n    }\n\n    private List<SSTableReader> getSStables(TableMetadata metadata, AbstractBounds<PartitionPosition> range)\n    {\n        return Lists.newArrayList(ColumnFamilyStore.getIfExists(metadata).getTracker().getView().liveSSTablesInBounds(range.left, range.right));\n    }\n\n    private UnfilteredRowIterator select(DecoratedKey partitionKey, TableMetadata metadata, ClusteringIndexFilter clusteringIndexFilter, AbstractBounds<PartitionPosition> range)\n    {\n        List<SSTableReader> sstables = getSStables(metadata, range);\n        if (sstables.isEmpty())\n            return UnfilteredRowIterators.noRowsIterator(metadata, partitionKey, Rows.EMPTY_STATIC_ROW, DeletionTime.LIVE, false);\n\n        List<UnfilteredRowIterator> sstableIterators = Lists.newArrayList();\n        for (SSTableReader sstable : sstables)","sourceCodeStart":151,"sourceCodeEnd":187,"githubUrl":"https://github.com/apache/cassandra/blob/88fd0f6a0eaed8943f05ac9e8f947882b8ddc8f1/src/java/org/apache/cassandra/db/virtual/PartitionKeyStatsTable.java#L151-L187","documentation":"The partition_key_stats table computes ranges by splitting the partitioner's token space, which only some partitioners support (e.g. Murmur3 and RandomPartitioner). In select(), if metadata.partitioner.supportsSplitting() is false, this InvalidRequestException is thrown naming the partitioner class, table, and keyspace.","triggerScenarios":"Querying partition_key_stats for a table that uses a partitioner without split support — notably OrderedPartitioner or ByteOrderedPartitioner based tables, or any custom partitioner not implementing supportsSplitting.","commonSituations":"Environments with tables migrated from older ordered-partitioner clusters; custom partitioner deployments; stats tooling pointed at non-Murmur3 tables.","solutions":["Restrict partition_key_stats queries to tables using a splitting partitioner (Murmur3Partitioner).","Migrate the target table to Murmur3Partitioner if full stats support is required.","Skip the table in stats-collection tooling when supportsSplitting is false.","If a custom partitioner is in use, implement/enable supportsSplitting or exclude it from analysis."],"exampleFix":"// before\n-- stats query against table using ByteOrderedPartitioner -> rejected\n// after\n-- confirm partitioner first:\nSELECT partitioner FROM system_schema.tables WHERE keyspace_name = 'ks' AND table_name = 'tbl';\n-- only query Murmur3Partitioner tables","handlingStrategy":"validation","validationCode":"Row r = session.execute(\"SELECT partitioner FROM system_schema.tables WHERE keyspace_name = ? AND table_name = ?\", ks, tbl).one();\nif (r != null && !r.getString(\"partitioner\").endsWith(\"Murmur3Partitioner\"))\n    throw new IllegalStateException(\"Partitioner does not support splitting: \" + r.getString(\"partitioner\"));","typeGuard":null,"tryCatchPattern":"try { session.execute(statsQuery); }\ncatch (InvalidRequestException e) { if (e.getMessage().contains(\"is not supported\")) { /* exclude this table from stats analysis */ } else throw e; }","preventionTips":["Only run partition_key_stats queries on Murmur3 (default) partitioned tables.","Filter out tables with ordered/custom partitioners in analysis tooling.","Check metadata.partitioner.supportsSplitting() programmatically when using the internal API."],"tags":["virtual-table","partitioner","unsupported","invalid-request"],"backgroundTag":"unsupported-operation","analyzedSha":"88fd0f6a0eaed8943f05ac9e8f947882b8ddc8f1","analyzedAt":"2026-09-10T07:29:22.284Z","contentChangedAt":"2026-09-10T07:29:22.284Z","schemaVersion":2},"datasetVersion":"2026-09-17T15:17:12.973Z"}