Postgresql: Calculate work days (none weekend days)
Posted by rich on Feb 15, 2008 in coding, Postgresql | 4 comments Coming from a MsSQL database with access queries/macros/modules and so on, its easy to be able to work out weekend days from two given dates, ie if you have two dates you can calculate how many days between them aren’t weekdays. In postgresql, this isnt so easy! there aren’t many examples on the net, without creating mass functions, but i’ve come up with this: SELECT count(*)...read more
