LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

date comparison

Solved!
Go to solution

The thrid message in this thread which was posted by you is marked as the solution.



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
0 Kudos
Message 11 of 20
(7,002 Views)

My apologies Mark

 

I meant no disrespect. I've fixed it now.

 

Thanks and best regards

Ray

Message 12 of 20
(6,999 Views)

Not a problem. I'm glad it worked out for you. BTW, I'm not sure your algorithm for the Julian Date is correct. It looks a bit different than what is described here.



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
0 Kudos
Message 13 of 20
(6,992 Views)

Mark

The Julian date vi is one I got off the NI Zone...there were actually two of them.,...one does the reversal.

 

 

Ray

0 Kudos
Message 14 of 20
(6,989 Views)
0 Kudos
Message 15 of 20
(6,986 Views)

The numbers look quite a bit different. Here is a revised, and a bit more readbale, version for comparison. BTW, your version is actually off by a day.

Calculate Julian Day Number.png



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
0 Kudos
Message 16 of 20
(6,978 Views)

Thanks Mark

 

I've coded it up and posted it here for anybody who might want it. How would we go about letting the NI Developer Zone know about this flaw?

 

Regards

Ray

0 Kudos
Message 17 of 20
(6,970 Views)

Good Afternoon Mark,

 

I will fix this flaw for you in Developer Zone.  Thank you both for finding this problem for us!

 

-Cody C

0 Kudos
Message 18 of 20
(6,945 Views)

 


@Cody C wrote:

Good Afternoon Mark,

 

I will fix this flaw for you in Developer Zone.  Thank you both for finding this problem for us!

 

-Cody C


I am trusting the examples of Julian Dates I found online. I would guess that it is a rounding issue in the algorithm that was posted originally. Either way, the formula node implementation is easier to read and matches the published algorithms I found. The pure LabVIEW implementation was a bit more convoluted.

 



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
0 Kudos
Message 19 of 20
(6,941 Views)

Well, thats what you get for looking at older code.  That does seam to be a bit Rube-Goldberg.  My Production test mainline defalts to 1 *.csv report per day with header.  So I need to add the header on the first run of the day.  Easy since the report is JJJJJReport.txt

 

Here's a snippet of the relevant parts

Uhmmmm.png

The Time Stamp is test start time- the format specifier %y%j gives me 11049 today


"Should be" isn't "Is" -Jay
0 Kudos
Message 20 of 20
(6,934 Views)