?
Solved

convert text from a field in access in a query

Posted on 2014-03-05
1
Medium Priority
?
517 Views
Last Modified: 2014-03-05
I have a table in access with a field "FileDate".
The data in that field is like (two sample lines)

"201078573470 2/24/2010 11:02:00 AM"
"201083243410 10/7/2010 10:30:00 AM"

I need to separate out the month / day / year in a query.
The result would be "2/24/2010" and "10/7/2010"
Is this possible?
0
Comment
Question by:drelinger
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 30

Accepted Solution

by:
hnasr earned 2000 total points
ID: 39907466
Try using:
Mid(FileDate, 13, 8)

If the first part is not fixed length then you need to check for the position of first / in the string.
In general:
Mid(FileDate, instr(1,FileDate,"/")-2,instr(instr(1,FileDate,"/"),FileDate, " ")-instr(1,FileDate,"/")+2)
0

Featured Post

Quick Cloud Training

Looking for some quick training on the cloud in 2 hours or less? Check out these how-to guides in AWS, Linux, OpenStack, Azure, and more!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Microsoft Access is a place to store data within tables and represent this stored data using multiple database objects such as in form of macros, forms, reports, etc. After a MS Access database is created there is need to improve the performance and…
Code that checks the QuickBooks schema table for non-updateable fields and then disables those controls on a form so users don't try to update them.
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …
Suggested Courses

801 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question