Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ SQL » Timestamp accuracy in postgres and upp
Re: Timestamp accuracy in postgres and upp [message #33299 is a reply to message #33092] Sat, 23 July 2011 09:15 Go to previous messageGo to previous message
mirek is currently offline  mirek
Messages: 13984
Registered: November 2005
Ultimate Member
Zbych wrote on Wed, 06 July 2011 09:02

I don't want to change TIME definition because of backward compatibility, but it is your decision.

In my application I keep some logs in a database. Once in a while another application transfers those logs from the database to main server and I use timestamp to remember which logs were already transfered.
If the last log has timestamp 17:00:00.5 (timestamp is added automatically by postgres), upp rounds it to 17:00:00. Next time I will search for logs with timestamp >17:00:00 and the log with timestamp 17:00:00.5 will be transfered again. That is why I need the same timestamp resolution in both upp and database.



What I am not getting is why it finds the log the first time, actually...

I mean, if the select is something like

Select().From(LOG).Where(timestamp >= 16:00 && timestamp < 17:00)

(and than move forward).

In fact, I am posting this because I have very similar arrangemnt in one of mine apps, so I would like to know if I am missing something Smile
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: SqlArray and data validation
Next Topic: [SQLITE] New version (3.7.0) introduces write-ahead logging.
Goto Forum:
  


Current Time: Tue Jun 11 22:27:10 CEST 2024

Total time taken to generate the page: 0.01869 seconds