Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

In Access Query, How to convert a date into a string 1

Status
Not open for further replies.

knuckelhead

Technical User
Aug 8, 2002
228
US
i have a qry. there is an autonumberID field named TransID and another field named ProdDate which is a date field.

In the Qry, i want to combine the 2 fields into a 3rd field named LotID. So if the first record for TransID is say 1 and the date is 7/3/2005, i want LotID to be 907032005.

The inventory count person would then see the last 8 digits of the Lot number as a date.

I was trying:

LotID:[TransID]+[ProdDate]
I am shooting for an answer like 907032005 for this record.
the next record would be 1007032005 and the next 1107032005 if i were inputting all 3 records on the same day.

i knew it would not work; i probably need some kind of STR command or such. Thanks for your help.
Glen
 
Something like this ?
LotID:[TransID] & Format([ProdDate], 'mmddyyyy')

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top