I can reformat it so that it’s at least legible…
v_lkw = (200 / traveltimeLkw) * 3.6,
JOIN dbo.DayCategory B
ON ONVERT(DATE, A.entrytime) = B.day
weekdayname = 'Mo'
AND roadcode = 'A23_1'
AND from2dk >= 9000
AND to2dk <= 10000;
As far as what may be wrong… No idea, We don’t know if you getting errors of an answer you don’t agree with.