General
ApexSQL add-ins general FAQs
SQL Server Management Studio and Visual Studio support
Does ApexSQL Refactor integrate with Visual Studio?
Yes, ApexSQL Refactor integrates into Visual Studio 2010 and higher
Which SQL Server version ApexSQL Refactor support?
Microsoft SQL Server 2005 and higher
Which SQL Server editions does ApexSQL Refactor support?
SQL Server Express, Standard, and Enterprise editions
Does ApexSQL Refactor support Azure SQL Database or SQL Server on Amazon RDS?
Yes. ApexSQL Refactor supports Azure SQL Database and SQL Server on Amazon RDS
Does ApexSQL Refactor support Azure SQL Database Managed Instance?
Yes, ApexSQL Refactor supports Azure SQL Database Managed Instance
Which version of SQL Server Management Studio ApexSQL Refactor support?
Microsoft SQL Server Management Studio 2012 and higher
You can use the latest full-featured backwards compatible SQL Server Management Studio for free. Click here
Does ApexSQL Refactor support Active Directory - Password authentication?
Yes, ApexSQL Refactor supports Active Directory - Password authentication
SQL formatter customization
Can I set up my own rules to format SQL?
Can I set up multiple user defined SQL formatter profiles?
Yes, you can have many different users defined SQL query formatter profiles
Can I distribute my SQL formatter options to other developers?
Yes. You can easily export and share all the SQL formatter options
Batch SQL formatter
Can I format SQL for multiple objects at once?
Can I format SQL for multiple scripts at once?
Yes, the Format SQL scripts feature can be used for formatting multiple SQL scripts at once
Using the batch SQL formatter, can I specify which objects to format SQL?
Yes, you can specify the list of script-based objects, for example stored procedures and functions that want to format
Can ApexSQL Refactor tell me which objects need to be formatted, so I can format SQL for those objects only?
Yes, the last column, "OK" under the Format SQL object window indicates whether the object is formatted properly, according to the specified format profile. A red X denotes that the object isn't formatted properly. A check mark, indicates the object is formatted properly. All objects that require formatting, will be pre-selected
Can I see the SQL object's script how it looks now and how will look like after formatting?
Yes, before executing the batch SQL query formatter, you can compare a SQL object's script as it now and how it will look like after clicking ‘OK' to format SQL.
Right click on the script object from the list in the Format SQL object window and click the Compare button or use the Ctrl + G shortcut:
Is there a "No format SQL" type tag to protect certain blocks of code from formatting?
Currently, no. This feature is planned for ApexSQL Refactor 2019 R2
Does the ApexSQL Refactor SQL formatter have a CLI to format SQL unattended?
Currently, no. This feature is planned for ApexSQL Refactor 2019
Formatting other
Can I obfuscate SQL code using ApexSQL Refactor?
Yes, SQL code can be obfuscated and make less readable
What options are available for obfuscation?
There are options for Wrapping, randomize keywords case and remove comments. All options are located under the Obfuscation tab of the Options dialog:
Can I preview the impact of changes?
Yes, ApexSQL Refactor has SQL code formatting impact preview which shows a clear insight and view of the impact of any formatting option changes immediately when you make them. If you don't like how it looks it can be easily changes and reverted without saving:
What SQL code is used to preview changes? Can I paste in my own?
By default, the predefined SQL code is used, but you can use SQL code that is in a SQL editor by clicking the Use current SQL button on the top right side of the Options dialog and preview changes:
Can I format selected blocks of code?
Yes, if in a SQL script wants to format only one part of the script and other parts to be non-formatted, just select that part and use Format SQL command either from the ApexSQL Refactor toolbar, ApexSQL Refactor main menu or right click in a query editor and from the context menu, choose command to format SQL code:
Does ApexSQL Refactor have options for casing of keywords (e.g. Select), built-in functions (e.g. Avg) etc.?
Yes, you can use ApexSQL Refactor formatting options under the Capitalization tab of the Options dialog to change the case of keywords, built-in functions, built-in data types, identifiers and variables
Does ApexSQL Refactor have option for expanding wildcards?
Yes, using the Wildcard expansion feature from ApexSQL Refactor you can expand SELECT * statements so that they list all of the columns that exist in the referenced tables. Doing this you can improve query performance and avoid syntax errors
Does ApexSQL Refactor have option for qualifying objects?
Yes, by using the Qualify object names feature to qualify the object. When the object in a SQL query is qualified SQL Server will not check if the current user is the owner of the object when executing a SQL query, meaning that no additional work will be required from SQL Server. This speed up the query execution
Refactoring
If I rename an object, will this change be applied to all its parent and children objects?
Can ApexSQL Refactor change stored procedures parameters?
Can I encapsulate T-SQL code using ApexSQL Refactor?
Yes, using Encapsulate code as feature you can creating a new stored procedure, a view, a scalar inline function, or a table inline function from any valid T-SQL code block.
Can I split table into two tables using ApexSQL Refactor?
Yes, ApexSQL Refactor can split a table in your database into two tables. This is useful when wants to normalize your database or improve database performance
Please visit the following article: How to set options for the Split table refactoring method on SQL Server
Can I replace a natural key with a surrogate key using ApexSQL Refactor?
Yes, for that in ApexSQL Refactor exist Add surrogate key feature, which can replace a complex natural key with a simple surrogate key thus keeping referential integrity, unifying key support for the whole database, and improving database refactoring performance
Other
Can I find unused variables and parameters in existing SQL Server stored procedures and functions using ApexSQL Refactor?
Yes, using the Unused variables and parameters feature from ApexSQL Refactor you can clean up your code by identifying and removing parameters and variables that aren't used
Can I convert SQL code to language-specific client code (e.g. C#)?
Is ApexSQL Refactor open source?
No, ApexSQL Refactor is not open source software