kirin123kirin/pytsql

fullname is nomatch alias.

Opened this issue · 0 comments

以下だとaliasとoriginalnameの対応関係が分からない

import pytsql

sql = """
insert into testdata (
SELECT a,b f
 from A as hoge 
 left join (select * from foo) as bar
 on hoge.a = bar.b 
 where a=1 and b is not null;
 )
"""

ret = pytsql.parse(sql)

実カラムはAとB

 ret.column_elem
['A', 'B']

でもaliasがあって、
alias "F"が、”A” , "B" のどっちと対応するのかがこれじゃあ分からない。

 ret.column_alias
['F']