I have about 12000 records that need to be changed from the format:
830 to 8-3
2710 to 27-1
Is there a command I could use to do that?
Thanks,
MIke
KARL DEWEY - 26 May 2006 17:52 GMT
[XX] is your field. I am assuming that you want to drop the right most
character and insert a dash between the left digits and penultimate character.
Left([XX],Len([XX])-2) & "-" & Left(Right([XX],2),1)
> I have about 12000 records that need to be changed from the format:
> 830 to 8-3
> 2710 to 27-1
> Is there a command I could use to do that?
> Thanks,
> MIke
boomtap - 26 May 2006 21:03 GMT
That worked amazingly well - I can't thank you enough.
>[XX] is your field. I am assuming that you want to drop the right most
>character and insert a dash between the left digits and penultimate character.
[quoted text clipped - 6 lines]
>> Thanks,
>> MIke
Rick B - 26 May 2006 17:55 GMT
I don't understand. You have a field with an entry of "830" and you want
that to turn into "8-3"?
You also have an entry of "2710" that you want to turn into "27-1"?
I don't see the pattern here. Are you simply dropping any zeros, then
inserting a dash before the last digit? Is this a text field or a number
field? Do you want the new value to replace what is currently in the table,
or are you simply trying to output this in a query or a report?

Signature
Rick B
>I have about 12000 records that need to be changed from the format:
> 830 to 8-3
> 2710 to 27-1
> Is there a command I could use to do that?
> Thanks,
> MIke