06-22-2017 06:15 AM
Hello,
in the attached after convering the date are 10 days missing, but anything else is right. See attached.
Thanks!
Solved! Go to Solution.
06-22-2017 06:29 AM - edited 06-22-2017 06:30 AM
That is because your formats do not equal at all.
1. You Format Date/Time does not have an AM/PM flag, but your Scan From String is expecting one.
2. Your Day and Month got flipped in your Scan From String compared to the Format Date/Time String. And apparently the month is truncated to 12.
06-22-2017 09:55 AM
06-22-2017 06:34 PM
is there an easy way to create these settings. I reordered the values, but that did not work. So I copied something close.
I guess below the surface its still the same representation, one bit for each second since 1904. Thats why it does not mess it up completely.
Its meant to come out as YYYY-dd-MM hh:mm:ss:ms, looks kind of right in MySQL. Except the ms are always .00
06-22-2017 08:03 PM - edited 06-22-2017 08:13 PM
Read
06-22-2017 08:09 PM - edited 06-22-2017 08:36 PM
actually the problem is, the date is limited to 12. Today its still 12, if it was to remove 10 days, would be 13
Maybe I can copy the format string from the advanced properties section in the properties of the indicator
edit: switched %d %m to %m %d, seems to work now
06-22-2017 08:16 PM - edited 06-22-2017 08:20 PM
The problem is you formatted it one way as month then day to go to a string, then then scanned from that string formatted back as day then month. You went from month 6 day 22, to day 6 month 22. Since there is no month 22, it became day 6 month 12.
That is what Crossrulz was telling you in his post.
For timestamp indicators, they take a value of a timestamp. The way they are displayed are determined by the format in the properties of that indicator.
Your %p is in an odd location. And when you use %p for am/pm, you want to use %I for the hour so it used a 12 hour clock. %H is for a 24 hour clock.
06-22-2017 09:06 PM
I cannot even remember why I did it. I think because I wanted the milliseconds to go into SQL
06-23-2017 07:45 AM - edited 06-23-2017 07:46 AM
actually, with wait until next multiple ms, when set to 1000ms at the 1st iteration its at some value. 2nd and further iterations are at 767 ms. If I set the timestamp not as unique value it does not matterten. 1st two rows have the same timestamp but from then on its one every 1s and its not trailing off.
I set another column as auto index, that gets me a running unique number, so I dont rely on time as unique number.