Skip to content

Conversation

chanmix51
Copy link

Window functions keywords like WINDOW, OVER, PARTITION were not recognized and the SQL formatting was bad when these functions were used.

Window function declarations were not indented correctly:

```
  from
    pomm.news window published_at_wdw as (
      order by
        published_at desc
    )
```

Configuring WINDOW as a top level reserved keyword makes the job:

```
  from
    pomm.news
  window
    published_at_wdw as (
      order by
        published_at desc
    )
```
@stof
Copy link
Contributor

stof commented Aug 14, 2015

The fact that you reformat the arrays of keywords/functions make it quite hard to see what is new in them

@chanmix51
Copy link
Author

@stof true, I have made a diff of before and after:

  • added WINDOW after INTERSECT
  • added OVER after OUTFILE

I have tested it in my own project's web debug toolbar and it works well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants