• Here is the corrected statement:

    SET @StartDate = convert(VARCHAR(10), getdate(), 101)

    + ' ' + (CAST(DATEPART(hh, (SELECT [Value] FROM tbltime WHERE NAME='TIME')) AS VARCHAR)

    + ':' + CAST(DATEPART(mi, (SELECT [Value] FROM tbltime WHERE NAME='TIME')) AS VARCHAR)

    + ':' + CAST(DATEPART(ss, (SELECT [Value] FROM tbltime WHERE NAME='TIME')) AS VARCHAR)

    -- unmark the line below if you want to display the miliseconds in the result

    --+ '.' + CAST(DATEPART(ms, (SELECT [Value] FROM tbltime WHERE NAME='TIME')) AS VARCHAR)

    )

    ** Don't mistake the ‘stupidity of the crowd’ for the ‘wisdom of the group’! **