Closed sivaramasubramanian closed 2 years ago
I have raised PR #978 with a fix that somewhat improves the performance.
@gjsjohnmurray Thanks for reviewing and merging the change.
When is the next release planned? Also, the NPM package for the formatter ( https://www.npmjs.com/package/@sqltools/formatter ) has not been updated in the last 2 years. Are there any plans to update the NPM package too?
Describe the bug Formatting the attached SQL Query with SQLTools formatter takes more than 25-30 seconds. I'm using an M1 Macbook Pro with 16GB RAM so the hardware must not be much of an issue here.
The Query has a large number of values in IN ( ... ) expression (around 5000), when formatted each of these values will be in a newline, this might be causing the slowness. When I reduce the no. of values in IN() the formatting is quicker
To Reproduce Steps to reproduce the behavior:
Expected behavior Formatting should be completed in less than 1s.
Desktop (please complete the following information):
Additional context sample.sql.txt