Community Tip - Visit the PTCooler (the community lounge) to get to know your fellow community members and check out some of Dale's Friday Humor posts! X
To Whom It May Concern:
Here is my question. I'd like to search for several text entities in my ACL script. For example, searching for &MP00002; and &M1229015a;. Below is what I did.
/* It works when there is one entity only. */
find -m -q -nowrap '&MP00002;';
/* None of the following tests works*/
find -m -q -e -nowrap '&MP00002;|&M1229015a;';
find -m -q -e -nowrap /&MP00002;|&M1229015a;/;
May I know what is the acceptable regular expression for it?
Best Regards,
Jing
Hi Jing,
I don't believe the regular expression flag -e allows for searching for multiple values.
You may have more luck trying something like this by setting up a slightly more complex statement performing two separate find commands and returning the first one found.
If you need help with that, the customizers on here are fantastic resources!
Hello Rafael,
Thank you very much for your great help. Yes, the regular expression -e wouldn't search for multiple values. I ended with the following command plus a group of text entities saved in an array for comparison to solve the problem.
find -m -e -q -nowrap /&[M][P]?[0-9]+[a]?;/
Best Regards,
Jing