Hi @Cant-We-Al-lJust- Get-Along ,
Welcome to the microsoft TSQL Q&A forum!
For this type of problem we recommend that you post CREATE TABLE statements for your tables together with INSERT statements with sample data.We also need to see the expected result of the sample.So that we’ll get a right direction and make some test.
Please try:
;WITH cte
as(SELECT * FROM yourtable
WHERE Datecolumn BETWEEN '2021-09-13' AND '2021-09-14')
SELECT * FROM cte
WHERE Timecolumn BETWEEN '05:00:00' AND ' 04:59:59'
If this does not solve your problem, please provide more information.
If you have any question, please feel free to let me know.
Regards
Echo
If the answer is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.