dbForge Studio for SQL Server can help you to format your SQL statements, paying attention to case, line breaks, whitespaces, indenting, wrapping, etc. Statements with errors are skipped and are not formatted.
Before you format your code, you might want to configure formatting options and customize case formatting profiles. To tune formatting options:
- On the Tools menu, point to Options. The Options dialog box opens.
- On the Options dialog box, navigate to Text Editor, Formatting.
- Apply required changes. For more information, refer to the Formatting topic.
To format the whole code of a document do one of the following:
- On the Text toolbar, click Format Document.
- Press Ctrl+K,D.
To format current statement:, do one of the following:
- On the Text toolbar, click Format Current Statement.
- Click Format Current Statement on the SQL Editor shortcut menu.
- Press Ctrl+K,S.
To format a certain code fragment:
- Highlight a required code fragment.
- Click Format Selection on the SQL Editor shortcut menu. Alternatively, press Ctrl+K,F.
Semicolon insertion
You can use dbForge Studio for SQL Server to insert missing semicolons after each statement in a query.
To insert semicolons, right-click the statement body, point to Refactoring, and then click the Insert Semicolons option. Alternatively, hold Ctrl and press B and then C.
Download dbForge Studio for SQL Server and try it absolutely free for 30 days!
Want to Find out More?
Take a quick tour to learn all about the key benefits delivered by dbForge Studio for SQL Server.
Get acquainted with the rich features and capabilities of the Studio in less than 5 minutes.
If you consider employing the Studio for your business, request a demo to see it in action.
Ready to start using dbForge Studio for SQL Server?