April 24, 2006 at 7:19 am
Im having trouble trying to make a string from the following variables
FH_Licence is a String , FH_TransmissionDate is a String ( mm/dd/yyyy ) , FH_FileSerialNumber is a String
FH_Licence = "213213" , FH_TransmissionDate = "04/24/2006" , FH_FileSerialNumber = "973"
for this example time = 13:05:52 ( hh:mm:ss )
The string is made up as follows
FH_Licence + FH_FileSerialNumber + JulianDate( FH_TransmissionDate ) + Hour + minute + second
Julian Date is made up of YYDDD ( year + right(000 + dayofyear, 3)
so in this case im looking for a return of
21321397306114130552
any help would be great as im getting stuck on the julian date bit
April 25, 2006 at 9:25 am
If you're doing the conversion to Julian date in VB code, look here:
http://www.novicksoftware.com/UDFofWeek/Vol2/T-SQL-UDF-Vol-2-Num-2-udf_DT_ToJulian.htm
...as you'll see there, your definition of Julian Date fits only one definition of Julian. All such definitions are dependent on date of origin.
In any case, you only really need to do a DATEDIFF() being careful to use the CORRECT "date of origin" for your situation, as the code you'll find in that link shows you.
April 26, 2006 at 2:31 am
Thank you Lisa I have now managed to resolve it
Viewing 3 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply