admin管理员组

文章数量:1418380

It's not clear to me what is the difference between these two commands available in SQLFluff:

fix       Fix SQL files.
format    Autoformat SQL files.

What is the difference between the two commands?

It's not clear to me what is the difference between these two commands available in SQLFluff:

fix       Fix SQL files.
format    Autoformat SQL files.

What is the difference between the two commands?

Share Improve this question edited Jan 29 at 18:07 jarlh 44.8k8 gold badges50 silver badges67 bronze badges asked Jan 29 at 17:05 Paul Razvan BergPaul Razvan Berg 21.7k13 gold badges88 silver badges133 bronze badges 1
  • I removed the <sql> tag since this isn't really an ISO/ANSI SQL related question. – jarlh Commented Jan 29 at 18:08
Add a comment  | 

1 Answer 1

Reset to default 1

From the docs:

format

Autoformat SQL files.

This effectively force applies sqlfluff fix with a known subset of fairly stable rules. Enabled rules are ignored, but rule exclusions (via CLI) or config are still respected.

So we see format is a reduced/simplified or less-aggressive version of fix. Though it's also possible the "effectively" weasel word here carries a lot of water.

本文标签: formattingWhat is the difference between the 39fix39 and the 39format39 commands in SQLFluffStack Overflow