Click here to Skip to main content
15,900,461 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
How to time data insert table in asp.net C#,I given some time data in below

OverTime
1:01
1:05
2:37
10:35
0:23
1:42
0:27
0:49
1:01
0:48

Above overtime data insert Table in sqlserver 2005,Time data type not available,so which data type using in sqlserver 2005 insert the data in asp.net C#
Posted

1 solution

Hi,

I have face the same problem, I have used DateTime my trick was I added 1st Jan 1900 with each time as the date of it

It will serve your purpose in sql server as well as in C#

e.g

var Time ="1-Jan-1900 "+"12:00";
 
Share this answer
 

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