[AccessD] Week of the Month

Joe Rojas JRojas at tnco-inc.com
Thu Jun 19 10:24:34 CDT 2003


Dim iwk As Integer

iwk = DatePart("ww", Date) - DatePart("ww", DateSerial(Year(Date),
Month(Date), 1))
iwk = iwk + 1
> -----Original Message-----
> From: ACTEBS [SMTP:actebs at actebs.com.au]
> Sent: Thursday, June 19, 2003 10:52 AM
> To:   access group
> Subject:      [AccessD] Week of the Month
>
> Guys,
> 
> Does anyone know of a method to work out what week it is of the month. For
> example, you have a range of  dates 1st January to 31st March. The 1st to
> the 7th is the 1st week of January and the 8th to the 14th is the second
> etc etc...
> 
> I have 2.5 years of data (about 1 Million rows) from an old main frame
> system and we are trying to determine the frequency of delivery to each
> customer on a per monthly basis. So effectively to say customer Jim
> Spanner the client delivers every second Thursday for February. Is there
> an elegant method of working this out? I have the date the delivery was
> carried out for the past 2.5 years, but am having difficulty working out
> how I could manufacture a frequency pattern.
> 
> Is there any method anyone could suggest, that I could explore...
> 
> AHGA
> 
> Regards
> Vlad
> 
>   << File: ATT5220503.txt >>
_______________________________________________
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com



This electronic transmission is strictly confidential to TNCO, Inc. and
intended solely for the addressee. It may contain information which is
covered by legal, professional, or other privileges. If you are not the
intended addressee, or someone authorized by the intended addressee to
receive transmissions on behalf of the addressee, you must not retain,
disclose in any form, copy, or take any action in reliance on this
transmission. If you have received this transmission in error, please notify
the sender as soon as possible and destroy this message. While TNCO, Inc.
uses virus protection, the recipient should check this email and any
attachments for the presence of viruses. TNCO, Inc. accepts no liability for
any damage caused by any virus transmitted by this email.


More information about the AccessD mailing list