X   Site Message
(Message will auto close in 2 seconds)

Welcome to UtterAccess! Please ( Login   or   Register )

Custom Search
   Reply to this topicStart new topic
> Simple Expression Builder Question, Access 2016    
post Aug 29 2019, 10:33 PM

Posts: 1
Joined: 29-August 19

I am creating the Access expression builder to create a field in a table, drawing from other fields in the same table.

I have an existing date field in the table that has the format dd/mm/yy.

I want to get the month from this existing date field.

The expression I am using is:

& Month([Date])

This works, but for single digit months (eg January), only return 1

I need the returned value to be 01.

Can someone please assist.
Go to the top of the page
post Aug 29 2019, 10:44 PM

Posts: 1,510
Joined: 2-April 09
From: somewhere out there...

& Format(Month([Date]), "00")
This post has been edited by arnelgp: Aug 29 2019, 10:45 PM

Never stop learning, because life never stops teaching.
Go to the top of the page
post Aug 29 2019, 10:50 PM

UtterAccess VIP
Posts: 11,208
Joined: 10-February 04
From: South Charleston, WV


Robert Crouser
Go to the top of the page
post Aug 29 2019, 11:29 PM

Access Wiki and Forums Moderator
Posts: 76,606
Joined: 19-June 07
From: SunnySandyEggo

Hi. Welcome to UA! welcome2UA.gif

Looks like this is crossposted here.

Just my 2 cents... "And if I claim to be a wise man, it surely means that I don't know" - Kansas
Access Website | Access Blog | Email
Go to the top of the page

Custom Search

RSSSearch   Top   Lo-Fi    21st November 2019 - 02:44 PM