Click here to Skip to main content
15,893,663 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi

I need to get a missing time from selected time within a daterange.

Eg.

Inputs

FromDate -18/10/2011,
Todate -19/10/2011
Starttime-8.00PM
EndTime -12.00AM

when i query a table with the above inputs i will get result as follows

18/10/2011 8pm- 9pm
18/10/2011 10pm-11pm
18/10/2011 11pm-12am

19/10/2011 8pm- 9pm
19/10/2011 9pm-10pm


What i need is

18-10/2011 8pm- 9pm
18-10/2011 9pm-10pm---------- this row i have to find.
18-10/2011 10pm-11pm
18-10/2011 11pm-12am

19/10/2011 8pm- 9pm
19/10/2011 9pm-10pm
19/10/2011 10pm-12am---------- this row i have to find.



I have to get this without using the any loop.

Thanks
Ageesh.
Posted
Comments
Toniyo Jackson 18-Oct-11 2:43am    
Share your sql query.
kishorekke 18-Oct-11 3:01am    
please send the query u wrote..

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900