date problem

I've two dates say 12/03/2006 11:40:0015/03/2006 14:20:00I need to calculate the no of nights between these two dates. Night is considered as between 9:00 p.m to 6:00 a.mAny related examples for this?
[236 byte] By [harinibiligiria] at [2007-11-27 7:02:40]
# 1
This article is in Dutch as well, but the provided code should look straightforward: http://balusc.xs4all.nl/srv/dev-jsw-dat.html#VerschilTussenDatumsBerekenen
BalusCa at 2007-7-12 18:53:44 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...