Module schema

Module schema 

Source
Expand description

Schema analysis module for FK-aware operations.

This module provides:

  • Data models for table schemas, columns, and foreign keys
  • MySQL DDL parsing for extracting schema information
  • Dependency graph construction with topological sorting
  • Cycle detection for handling circular FK relationships

Structs§

Column
Column definition within a table
ColumnId
Unique identifier for a column within a table
ForeignKey
Foreign key constraint definition
Schema
Complete database schema
SchemaBuilder
Builder for constructing schema from DDL statements
SchemaGraph
Schema dependency graph built from foreign key relationships.
TableId
Unique identifier for a table within a schema
TableSchema
Complete table schema definition
TopoSortResult
Result of topological sort

Enums§

ColumnType
SQL column type classification

Functions§

extract_alter_table_name
Extract table name from ALTER TABLE statement
extract_create_table_name
Extract table name from CREATE TABLE statement
parse_column_list
Parse a comma-separated column list, stripping backticks and whitespace
split_table_body
Split table body by commas, respecting nested parentheses