AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |
Back to Blog
Github baseelements3/16/2023 ![]() ![]() And I am willing to bet steak dinner and a bottle of good wine that you don't need regular expressions to solve this issue. But regex is *extremely abstract* and can get absurdly complex. ![]() You don't sound like an experienced or advanced FileMaker developer and so I URGE you to leave regex alone! Regular expressions are indeed extraordinarily powerful and I've solved data analysis problems with regex that couldn't have been solved any other way. It's a natural thing for an experienced, advanced developer to suggest. I see others have suggested the use of regular expressions (regex). Right? Then you might start having to use Left(), Right(), and perhaps Position() to sort things out. From one of the previous responses though it sounds like the number of characters you need from the left is actually determined by the length of the input string. If you just want to get a fixed number of characters from the left of the input string (which is what I understand from your original post) then that's all you need. A Let statement with more than one test - like the one above - has to be wrapped in square brackets, as I did a one-test Let statement doesn't. LeftChars = Case ( OrderType="Cash", 6, 10 ) ![]() ParseMe = MyTable::Whatever // field value? So you might use a formula like this: Let ( [ Let me imagine that field is called, oh, OrderType. I'm guessing you've got a value in another field that determines whether you need to parse the string one way or the other. If they don't, why do you need to put them into variables? Do the required character lengths CHANGE? Sounds like they don't. ![]()
0 Comments
Read More
Leave a Reply. |