Home Forums SQL Server 2012 SQL Server 2012 - T-SQL check that column has one and only one value and the value is the value I want RE: check that column has one and only one value and the value is the value I want

  • Using SQL Server 2012 function in use

    select * from

    (

    select

    *,CUME_DIST () OVER (PARTITION BY marker ORDER BY val)-

    RANK() OVER (PARTITION BY marker ORDER BY val ) AS PctRank

    from

    #Temp t

    )T1 where PctRank=0

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server