Separate .dbf data at a comma

  • Thread starter Thread starter Dave
  • Start date Start date
D

Dave

I have import a data table that uses the long date format. I want to
separate the date in these records at the comma, beginning from the left.

Is there an easy formula that will look for a comma and then make each of
the pieces into separate columns?

Example: Sunday, October 5, 2003 would = Column 1 = Sunday Column 2 =
October 5 Column 3 = 2003

Thanks
 
Is the imported field a text field or date field.
Is there a particular reason why you would want to store the parts of a date
into separate fields?
If this is a text field, you might be able to use CDate([YourField])

Duane Hookom
MS Access MVP
 
I want to strip the Day of the Week so that I can stack rank those that
posted data.

It is a text field when it comes in.


Duane Hookom said:
Is the imported field a text field or date field.
Is there a particular reason why you would want to store the parts of a date
into separate fields?
If this is a text field, you might be able to use CDate([YourField])

Duane Hookom
MS Access MVP

Dave said:
I have import a data table that uses the long date format. I want to
separate the date in these records at the comma, beginning from the left.

Is there an easy formula that will look for a comma and then make each of
the pieces into separate columns?

Example: Sunday, October 5, 2003 would = Column 1 = Sunday Column
2
=
October 5 Column 3 = 2003

Thanks
 
Add a date type field to your table and update it using an expression like:
=CDate(Mid([Example],Instr([Example],",")+2))

--
Duane Hookom
MS Access MVP

Dave said:
I want to strip the Day of the Week so that I can stack rank those that
posted data.

It is a text field when it comes in.


Duane Hookom said:
Is the imported field a text field or date field.
Is there a particular reason why you would want to store the parts of a date
into separate fields?
If this is a text field, you might be able to use CDate([YourField])

Duane Hookom
MS Access MVP

Dave said:
I have import a data table that uses the long date format. I want to
separate the date in these records at the comma, beginning from the left.

Is there an easy formula that will look for a comma and then make each of
the pieces into separate columns?

Example: Sunday, October 5, 2003 would = Column 1 = Sunday
Column
 
Back
Top