[#6309] fixed fields extraction for view query with multi-level comments

This commit is contained in:
Gani Georgiev
2025-01-18 12:11:36 +02:00
parent 2317695011
commit b8ea953059
2 changed files with 22 additions and 10 deletions

View File

@@ -246,11 +246,21 @@ func TestCreateViewFields(t *testing.T) {
`
select
-- test single line
id,
text,
demo1.id,
demo1.text,
/* multi
line comment */
url, created, updated from demo1
demo1.url, demo1.created, demo2.updated from demo1
-- comment before join
join demo2 ON (
-- comment inside join
demo2.id = demo1.id
)
-- comment before where
where (
-- comment inside where
demo2.id = demo1.id
)
`,
false,
map[string]string{