Link to home
Start Free TrialLog in
Avatar of Chuck Lowe
Chuck Lowe

asked on

T-SQL what is it doing ?

I have this bit of sql code. Can anyone tell me what the "VALUE_DATE_OFFSET_NO,-20" and "VALUE_DATE_OFFSET_NO,20" gives me?
No comments in the code. What is this trting to acheive?
Is it saying to subtract 20 from the column and add 20 to the column for the declared variables?

DECLARE @MinCapacityOffset INT
DECLARE @MaxCapacityOffset INT


-- Look up the minimum and maximum offsets specified in the Capacity standards table.
SELECT            @MinCapacityOffset = MIN(ISNULL(TCAPACITY.VALUE_DATE_OFFSET_NO,-20)),
            @MaxCapacityOffset = MAX(ISNULL(TCAPACITY.VALUE_DATE_OFFSET_NO,20))
FROM            TCAPACITY
ASKER CERTIFIED SOLUTION
Avatar of Scott Pletcher
Scott Pletcher
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Chuck Lowe
Chuck Lowe

ASKER

Thanks. I must of had a brain fart.
Thanks again.