Hello, I have a table that I would like to add a column as a group number. The group number will be based on date, so any record with the same date will be in the same group. Here is an example of what I want after my update.
DECLARE @Dates TABLE (MyDateTime DATETIME, MyGroup INT);
INSERT INTO @Dates (MyDateTime, MyGroup) VALUES
I have MyDateTime and want to populate MyGroup. The actual data have different number of date/time values.
Since this is groups I do not know if RANK can be used (I did not think so).