Ok, I'm an idiot. I was thinking I had to add a character to replace the unknown values but if I just use 202401 for January 2024 and 20240101 for January 1st 2024 it sorts fine. If I don't know the day I certainly won't know the time. Anyway, thanks to all who looked at this and those who tried to help.