Hello, I need to perform an update where I set the value to something like this:
dateone ~ datetwo
12/12/2008 ~ 12/14/2008
I'm converting the datetime into varchar and then attempting to concatenate the values and finely perform the update.
This is what I have but am getting the following error:
Msg 157, Level 15, State 1, Line 1
An aggregate may not appear in the set list of an UPDATE statement.
set Date = (Select CONVERT(varchar(10),MIN(PR.[Date]),101) + '~' + CONVERT(varchar(10),MAX(PR.[Date]),101) )
from LMVR_PropertyReservations PR
INNER JOIN #Reservations R
ON R.Propertyid = PR.Propertyid