Avatar of jjxia2001
jjxia2001

asked on 

Need help to format text field in ACCESS data table

I have a field in an Access table to show three quotes such as this: """0-2,500""". I want to change it to "0-2,500".  How do I delete the extra ".  The length in the middle is not same, may have """2,500-5,000""" or """5,000-10,000""".

I tried MID function, but need the length: MID(fieldName,3,length), length is varied.

Please help
Microsoft Access

Avatar of undefined
Last Comment
jjxia2001
Avatar of jerryb30
jerryb30
Flag of United States of America image

Try replace(replace(yourField, chr(34)chr(34), chr34), chr(34)chr(34), chr(34))
Avatar of jjxia2001
jjxia2001

ASKER

Got invalid syntax error.
SOLUTION
Avatar of Patrick Matthews
Patrick Matthews
Flag of United States of America image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Avatar of jerryb30
jerryb30
Flag of United States of America image

Try replace(replace(yourField, 'chr(34)chr(34)', 'chr34'), 'chr(34)chr(34)', 'chr(34)')
jerryb30,

I think you are missing some concatenation operators :)

Patrick
jjxia2001,

Did you try either of mine?

Patrick
SOLUTION
Avatar of jerryb30
jerryb30
Flag of United States of America image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
ASKER CERTIFIED SOLUTION
Avatar of Ken Butters
Ken Butters
Flag of United States of America image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
Avatar of jjxia2001
jjxia2001

ASKER

All three ways worked, but I like the one from buttersk.  Thanks all!
Microsoft Access
Microsoft Access

Microsoft Access is a rapid application development (RAD) relational database tool. Access can be used for both desktop and web-based applications, and uses VBA (Visual Basic for Applications) as its coding language.

226K
Questions
--
Followers
--
Top Experts
Get a personalized solution from industry experts
Ask the experts
Read over 600 more reviews

TRUSTED BY

IBM logoIntel logoMicrosoft logoUbisoft logoSAP logo
Qualcomm logoCitrix Systems logoWorkday logoErnst & Young logo
High performer badgeUsers love us badge
LinkedIn logoFacebook logoX logoInstagram logoTikTok logoYouTube logo