Paul McNett wrote: >>> A bazillion quote marks, or 1000 like your REPLACE command? >> Bazillion. I figured if I used 1000 in my STRTRAN that I could knock >> off most and just leave the last <1000 in there. It would be ideal to >> remove all of the extra crap, and I think I chose the 1000 instead of >> something like 3 because I figured it would clean it up faster handling >> larger chunks at a time. > > Makes sense. Although, why not clean 'em all up in one swoop, since you > are going to the trouble anyway.
Well yes, the ideal replace would be a factor of 2 instead of 1000. I only chose the 1000 figure thinking that it might be quicker for getting it down to a manageable size and then doing a STRTRAN for the remain <1000 with the factor of 2. > > >>> Where are the quote marks? After valid data, before valid data, or >>> interspersed? >> Interspersed...something like good text, following by literally >> thousands of single quotes with some more text mixed in. Rinse and >> repeat. Nasty looking. > > Actually, this sounds like a fun project! :) Fun as in a good challenge to try and create this tool for the tech support guys to use rather than me having to manually manipulate the data, yes! > > >>> Get the data out of the memo fields, into a temp file, and use low-level >>> file operations to parse the input file into an output file, and finally >>> write the sanitized contents of the output file back into your memo field. >> Looks like that's all I'll be able to do I guess. Thanks. > > It'll be fast, and you could deal with a byte or a chunk of bytes at a > time. Luckily, you are only searching for ['] characters, however you'll > undoubtedly need to be intelligent enough not to delete ['] characters > that were intended. > > I think if I were doing this I'd write a generic function to take a > Empty object (you know, the one created by SCATTER MEMVAR MEMO Name) > containing the memo field, and the return would be another Empty object > with the sanitized contents. Any variable...or property of such a variable, would hit the limit of 16777184. I'll have to use LLFF to avoid this. > > Or you could have two modes: one a dry-run that only reports which > records have been identified as needing sanitizing, and what would be > sanitized, and another mode that actually makes the changes. Quick and dirty tool needed for now...not too much glamor (or 'glamour' for you UK blokes!). _______________________________________________ Post Messages to: [email protected] Subscription Maintenance: http://leafe.com/mailman/listinfo/profox OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech Searchable Archive: http://leafe.com/archives/search/profox This message: http://leafe.com/archives/byMID/profox/[EMAIL PROTECTED] ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

