pub fn transpile(
sql: &str,
read: DialectType,
write: DialectType,
) -> Result<Vec<String>>Expand description
Transpile SQL from one dialect to another.
§Arguments
sql- The SQL string to transpileread- The source dialect to parse withwrite- The target dialect to generate
§Returns
A vector of transpiled SQL statements
§Example
use polyglot_sql::{transpile, DialectType};
let result = transpile(
"SELECT EPOCH_MS(1618088028295)",
DialectType::DuckDB,
DialectType::Hive
);