Roll Days to a month in Access

Mac1206

Board Regular
Joined
Jun 3, 2016
Messages
184
I have a Shipping_day Column that I need to turn into months and need some help on how to obtain this goal please...Thanks in Advance...

[TABLE="width: 243"]
<colgroup><col><col><col></colgroup><tbody>[TR]
[TD]Invoice[/TD]
[TD]Invoice_Item[/TD]
[TD]Shipping_Day[/TD]
[/TR]
[TR]
[TD]97749302[/TD]
[TD]10[/TD]
[TD]1/5/2017[/TD]
[/TR]
[TR]
[TD]97767388[/TD]
[TD]40[/TD]
[TD]1/10/2017[/TD]
[/TR]
[TR]
[TD]97767388[/TD]
[TD]50[/TD]
[TD]1/10/2017[/TD]
[/TR]
[TR]
[TD]97778915[/TD]
[TD]90[/TD]
[TD]1/4/2017[/TD]
[/TR]
[TR]
[TD]97793659[/TD]
[TD]20[/TD]
[TD]1/9/2017[/TD]
[/TR]
[TR]
[TD]97793660[/TD]
[TD]20[/TD]
[TD]1/11/2017[/TD]
[/TR]
[TR]
[TD]97793660[/TD]
[TD]21[/TD]
[TD]1/11/2017[/TD]
[/TR]
[TR]
[TD]97800777[/TD]
[TD]20[/TD]
[TD]1/5/2017[/TD]
[/TR]
[TR]
[TD]97807265[/TD]
[TD]50[/TD]
[TD]1/5/2017[/TD]
[/TR]
</tbody>[/TABLE]


Result would be:
Group by Month:January, February, March, etc., instead of the short date above....
 

Excel Facts

Workdays for a market open Mon, Wed, Friday?
Yes! Use "0101011" for the weekend argument in NETWORKDAYS.INTL or WORKDAY.INTL. The 7 digits start on Monday. 1 means it is a weekend.
Within a query the Format$ function can be used to format a date into a month:

Code:
SELECT *, [COLOR=#0000FF]Format$(Shipping_Day,"mmmm") AS ShippingMonth [/COLOR]FROM [I][B]MyTable[/B][/I]
 
Upvote 0
Within a query the Format$ function can be used to format a date into a month:

Code:
SELECT *, [COLOR=#0000FF]Format$(Shipping_Day,"mmmm") AS ShippingMonth [/COLOR]FROM [I][B]MyTable[/B][/I]

Thanks, that worked perfectly....
 
Upvote 0
Code:
SELECT *,  month ( Shipping_Day ) AS ShippingMonth FROM MyTable

if the month number is good enough this will work too

and you probably won't notice, but format is slower
 
Upvote 0

Forum statistics

Threads
1,225,611
Messages
6,185,996
Members
453,334
Latest member
Prakash Jha

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top