Options

CASE

Hi Redgate Team,

SQL Prompt formats the following code like below:

SET @sql =
    N'SELECT name FROM sys.databases WHERE 1=1'
    + CASE WHEN @system_only = 1 THEN ' AND database_id IN (1,2,3,4)' ELSE '' END
    + CASE WHEN @dblist IS NOT NULL THEN ' AND name IN (' + @dblist + ')' ELSE
                                                                          '' END;
The last END should be aligned with CASE or should be on the same line.

Thanks for fixing it!

Style attached...

Torsten
MVP

Answers

Sign In or Register to comment.