How can we help you today? How can we help you today?

Formatting adds unneeded spaces

Hi!

The formatting seems to add additional spaces after the last SELECT and WHERE which are unneeded.
Would be nice to get this sorted -thanks!

--get the transactions covered by the active CFPs
DECLARE @lower_bound_tsn bigint ;
DECLARE @upper_bound_tsn bigint ;
SELECT
@lower_bound_tsn = MIN(xcf.lower_bound_tsn)
, @upper_bound_tsn = MAX(xcf.upper_bound_tsn)
FROM sys.dm_db_xtp_checkpoint_files AS xcf
WHERE
xcf.file_type = 2
AND xcf.state = 2 ;
SELECT * FROM sys.fn_dblog_xtp(NULL, NULL) WHERE tx_end_timestamp BETWEEN @lower_bound_tsn AND @upper_bound_tsn ;
torsten.strauss
0

Comments

1 comment

  • Dan B
    Hi Torsten,

    I haven't been able to replicate this locally. Is the code you are putting in the forum the before or after?

    If I paste it into SSMS and use Prompt to format it looks okay to me coming out as

    DECLARE @lower_bound_tsn BIGINT;
    DECLARE @upper_bound_tsn BIGINT;
    SELECT @lower_bound_tsn = MIN(xcf.lower_bound_tsn) ,
    @upper_bound_tsn = MAX(xcf.upper_bound_tsn)
    FROM sys.dm_db_xtp_checkpoint_files AS xcf
    WHERE xcf.file_type = 2
    AND xcf.state = 2;
    SELECT *
    FROM sys.fn_dblog_xtp(NULL, NULL)
    WHERE tx_end_timestamp BETWEEN @lower_bound_tsn
    AND @upper_bound_tsn;
    Dan B
    0

Add comment

Please sign in to leave a comment.