apache / apache/datafusion-sqlparser-rs
AS Keyword added by default even if not specified on original SQL statement
- Lenguaje dominante
- Rust
- Estrellas
- 3.5k
- Forks
- 772
- Merge medio
- 4 d 9 h
- PR fusionados (30 d)
- 17
Descripción
Hi all,
I am writing you after @TylerBrinks suggested me to open a discussion on the issue mentioned in title.
Basically I am using the C# porting version of Rust one (thanks Tyler) using the Generic dialect in an Oracle
scenario. I know that is not the perfect usage but what happens is that when I parse a SQL statement that do not
have the AS clause specified the dialect automatically add it which causing Oracle error when trying to execute it.
I have tried to create a new dialect for Oracle but I didn't find a way (at least in the c# version) where to override
the default AS clause inserted. I proposed @TylerBrinks some changes to his porting code but he objected that was better to open a discussion here on this topic.
Please I am open to any solution like:
1- Write a new Oracle dialect class giving me the possibility to override the default AS clause
2- Remove default AS clause
Thanks in advance
Regards
Luigi
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Línea de trabajo
Comienza reproduciendo el parseo de Generic para una sentencia sin una cláusula AS y, después, sigue el recorrido hasta determinar dónde se selecciona la representación de alias específica del dialecto. Compara el SQL generado por el parser con el requisito de Oracle y determina si es apropiado un dialecto Oracle o un comportamiento de AS configurable. Se considera terminado cuando el comportamiento elegido está cubierto y no se emite ninguna cláusula AS no deseada para el caso de Oracle.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- rust, sql
- Área
- databases
- Tipo de issue
- Error
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Estado de actividad
- Estancado
- Claridad
- Bastante claro
- Aptitud para principiantes
- 35/100