Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Help With String Time Value - Math
Message
 
À
Tous
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Syntaxe SQL
Titre:
Help With String Time Value - Math
Versions des environnements
SQL Server:
SQL Server 2000
Application:
Desktop
Divers
Thread ID:
01372446
Message ID:
01372446
Vues:
62
I am trying to figure out how to code a stored procedure to return elapsed time values. The date portion is stored in the RecDateTime, the fields UpTime1 and DownTime1 have string values such as 15:30 and 15:45. The goal is turn return an additional column show the difference between UpTime1 and DownTime1, in this case it would be 15 minutes.

A hitch in the plan is that if there is not a value in UpTime1 and/or DownTime1 then I want to return a zero.
RecDateTime                        UpTime1         DownTime1
01/09/2009 12:13:00               15:30                15:45
RecDateTime is a datetime value
UpTime1 and DownTime1 are varchr(5)

Thanks for any help.

Kirk
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform