our friend the win32 system timer.
"Merlin Moncure" <[email protected]>
| Newsgroups | gmane.comp.db.postgresql.devel.win32 |
|---|---|
| Message-ID | <[email protected]> |
Depending on how you look at it, this may be a semi-serious problem in win32. pg uses the C library time routines to calculate elapsed time and supply values. Unfortunately, this value is only updated for each timeslice allocated to the thread. The resolution of this timer is about 10 ms... This means that a table with a timestamp column defaulted to now() and a unique constraint on that column will have a very high chance of constraint violations. This might happen when reading in values from a script, and it works fine on Linux. A side issue is that psql analyze timings are not useful below 10 ms. Should the win32 high performance counter, QueryPerformanceCounter, be introduced? Merlin ---------------------------(end of broadcast)--------------------------- TIP 4: Don't 'kill -9' the postmaster