Skip to main content

first_table_name

Function first_table_name 

Source
pub fn first_table_name(sql: &str) -> Option<&str>
Expand description

返回 SQL 中首个 FROM 表引用(跳过字符串与注释,递归处理子查询)。

供路由与表判定复用(wp-oml 的 resolve_sql_route 也使用本实现)。