Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 4565 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

Hello, I need to process a string on over 6000+ records and will eventually become an automated routine, basically I need to clean a string which will be implemented in web publishing and I would like to know if there is a way with just 1 step to read a string and replace all the alphanumeric values (meaning a value that contains both numbers and letters) in uppercase.

I already have a custom function that cleans the string based on the on the symbols I don't need.

These would be a few examples of what I need to do:

Original: Ultra2 SCSI Cable

New: ULTRA2 SCSI Cable

Original: CMOS Battery (7.2V, 15Mah)

New: CMOS Battery (7.2V, 15MAH)

Original: 68 To 50pin SCSI Adapter

New: 68 To 50PIN SCSI Adapter

Original: 146.8gb SCSI Hard Drive

New: 146.8GB SCSI Hard Drive

Thanks in advance for the help, if you need further information just let me know.

Posted

You will need either a custom function or a looping script to go over each word in the text. Having to keep the surrounding punctuation (e.g. parentheses) is an additional complication.

Posted

Thanks for the replies, Lee, I've seen the file but its pretty basic compared to what I'm trying to do, like I said, this is process that will require 6000+ lines to be cleaned up, with new text coming in, the whole purpose is to detect all the alphanumeric words in a string or sentence and make them uppercase, I don't know every single alphanumeric value in all those lines, I just input examples, but making a value list or just replacing / substituting specific words will be very limited to only those words instead of being an intelligent script and find every word that contains both letters and numbers and applying and upper style.

Posted

I have created a sample db that does what I need to do, I'm just using globals instead of variables but there are many ways to work with this data, the only problem is that It works based on a loop process, So what I'm trying to figure out is if there's any way to just simply replace contents in a field where the alphanumeric values are recognized and the upper function can be applied that way it's just 1 step, quicker / simpler / better.

anyways here it goes

Elkpodemiami.zip

Posted

I haven't installed version 12 yet, so I cannot see what you - or Lee - have done. Still, I don't know of a way to achieve what you have asked for without looping. On the bright side, it can probably be assumed that for the current purpose, "words" will always be separated by spaces, so you can start with substituting spaces by carriage returns, then looping on the resulting values - see the attached.

UpperizeCF.fp7.zip

Posted

I saw your file and the custom function you applied does the job very well, I still can't figure out the function correctly, I mean, I see what its doing but I dont understand it completely.

Thanks for helping me out =)

Posted

Ohhh ok, I studied it more carefully and basically what you do is to call the function again until the the total value reaches 1, so you make a loop into the function itself, pretty smart, works very well, thank you very much.

Posted

call the function again until the the total value reaches 1

No, not really. You process the first value, then call the function again with the remaining values, until you run out of values to process.

Posted

Gotcha, I missunderstood that part, I already applied it, in my case instead of creating a calculation field I just "replace contents" along with that custom function and did the job, I think that It's much efficient to use the replace contents with that custom function than a script with loop to go to every single record / word in the string

Thanks a lot =)

Posted

Hi comment,

You didn't miss anything from me, I just threw out a basic substitute calculation to see what kind of a response the original poster would make. when I saw his file then I knew where he was headed. I was going to post a grip Find / Replace for text Editor, but your file out did What I came up with.

Incredible file, I wished I could think the way you do.

Lee

This topic is 4565 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.