InVision 2.6.1 introduces 23 new features and enhancements. The most interesting new feature in this release is probably the support for macros in SQL Reports and SQL Scripts. Macros enables you to use C# to dynamically generate SQL queries at runtime, before they are executed. You no longer need to concat a string using SQL and then execute it using sp_executesql. For details about how to use macros, you should read this blog post, which goes into details on the subject.
Macros can be used in Reports and SQL Scripts to dynamically create and execute SQL queries at runtime without using SQL string concatenation to construct them and sp_executesql for execution. Macros are written in C#, which offers great flexibility for creating both simple and very complex macros.