• I don't even know how to spell "SSRS" but, if I were to do something like this in T-SQL, here's one way to do it IF there were always going to be just 2 decimal places. Hopefully, you can connvert it to the language of SSRS.

    --===== Create some test data. This is NOT a part of the solution.

    DECLARE @SomeTable TABLE (SomeDecimal DECIMAL(9,2));

    INSERT INTO @SomeTable (SomeDecimal)

    SELECT 1.50 UNION ALL

    SELECT 6.00 UNION ALL

    SELECT 0.70 UNION ALL

    SELECT 0.03 UNION ALL

    SELECT 100.01 UNION ALL

    SELECT 0.00

    ;

    --===== This could be turned into an Inline Table Valued Function for ease of use.

    WITH

    cteSplit AS

    (

    SELECT IntPart = CAST(CAST(SomeDecimal AS INT) AS VARCHAR(30)),

    DecPart = RIGHT(SomeDecimal % 1, 2)

    FROM @SomeTable

    )

    SELECT IntPart

    + ISNULL('.' + NULLIF((LEFT(DecPart,1) + ISNULL(NULLIF(RIGHT(DecPart,1),'0'),'')),'0'),'')

    FROM cteSplit

    ;

    As a bit of a sidebar, this is an unusual report display requirement. Why do they want it this way?

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)