t8y2/dbx · error
type details are not supported in MySQL compatibility mode
Error message
type details are not supported in MySQL compatibility mode
What it means
getTypeDetails refuses to run PostgreSQL catalog queries against a server running in MySQL compatibility mode, where sys_catalog SQL is invalid. The agent fails fast with this explicit error instead of emitting confusing SQL errors.
Source
Thrown at agents/drivers/vastbase-go/vastbase_metadata.go:594
LEFT JOIN %s opc ON opc.oid = r.rngsubopc
LEFT JOIN %s ncan ON ncan.oid = pcan.pronamespace
LEFT JOIN %s ndiff ON ndiff.oid = pdiff.pronamespace
LEFT JOIN %s nopc ON nopc.oid = opc.opcnamespace
WHERE r.rngmultitypid = %%d`, rangeSubtype, rangeTable, typeTable, namespaceTable, typeTable, namespaceTable, procTable, procTable, opclassTable, namespaceTable, namespaceTable, namespaceTable),
rangeMultirange: fmt.Sprintf(`SELECT mt.typname
FROM %s r
JOIN %s mt ON mt.oid = r.rngmultitypid
WHERE r.rngtypid = %%d`, rangeTable, typeTable),
collationName: fmt.Sprintf(`SELECT quote_ident(ncl.nspname) || '.' || quote_ident(cl.collname) FROM %s cl JOIN %s ncl ON ncl.oid = cl.collnamespace WHERE cl.oid = %%d`, collationTable, namespaceTable),
}
}
// getTypeDetails returns read-only details of a user-defined type. MySQL
// compatibility mode is explicitly unsupported instead of running PostgreSQL
// catalog SQL against a MySQL-mode server.
func (s *server) getTypeDetails(schema, name string) (*customTypeDetails, error) {
if s.mode.mysqlCompat {
return nil, errors.New("type details are not supported in MySQL compatibility mode")
}
schema = strings.TrimSpace(schema)
name = strings.TrimSpace(name)
if schema == "" || name == "" {
return nil, errors.New("schema and type name are required")
}
if isSystemSchema(schema) {
return nil, fmt.Errorf("system schema %s is not supported for custom type details", schema)
}
catalog := "sys_catalog"
if s.mode.postgresCatalog {
catalog = "pg_catalog"
}
prefix := catalogPrefix(catalog)
queries := customTypeCatalogQueriesFor(catalog, prefix, schema, name)
rows, err := s.metadataQuery(queries.general)
if err != nil {View on GitHub (pinned to c0390bff16)
Solutions
- Switch the database out of MySQL compatibility mode if type details are needed
- Avoid custom-type metadata RPCs on MySQL-compat-mode servers; rely on the metadata the agent supports there
- Reconnect with a mode where postgresCatalog/sys_catalog queries are valid
Defensive patterns
Strategy: validation
Validate before calling
if serverMode.MySQLCompat { skipTypeDetails() } else { agent.GetTypeDetails(ctx, schema, name) } Try / catch
d, err := agent.GetTypeDetails(ctx, schema, name)
if err != nil && strings.Contains(err.Error(), "MySQL compatibility") { return ErrTypeDetailsUnsupported } Prevention
- Check the server compatibility mode after connect
- Hide/disable custom-type detail UI in MySQL-compat mode
- Document mode capability differences in client feature flags
When it happens
Trigger: Calling the custom-type details metadata RPC on a vastbase/openGauss server configured with MySQL compatibility mode (s.mode.mysqlCompat true).
Common situations: Connecting the agent to a MySQL-compat-mode database and then inspecting user-defined types; a config where the compat mode was enabled server-side but the client assumed PostgreSQL catalog support.
Related errors
- type details are not supported in MySQL compatibility mode
- system schema %s is not supported for custom type details
- Object source is not supported
- Object source is not supported
- Object source is not supported
AI-assisted analysis of t8y2/dbx@c0390bff16 (2026-09-05).
Data as JSON: /api/errors/faf5459092b7f6c7.
Report an issue: GitHub.