Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Other Forums
 MS Access
 Take the year and month out of a date/time field

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2004-06-10 : 08:10:15
Nevin writes "I need to take the year and month (month is in numerical form) out of the date/time field in an Access Database and then join that data into one field. I know how to take the year and month out (using DatePart), but when i do that the data becomes integers. Then, when i want to combine them into one field, i try using a +, but what i end up with is it adding together the numerical year and month data.

Help!"

RickD
Slow But Sure Yak Herding Master

3608 Posts

Posted - 2004-06-10 : 09:23:31
Str(datepart("mm",date)) & Str(datepart("yyyy",date))
Go to Top of Page
   

- Advertisement -