Udai Mathur

Udai Mathur

  • NA
  • 49
  • 11.1k

Need Regular Expression Logic to find string

Jun 28 2019 1:41 AM
Hello,

I want to find a particular string (word) from a sentance.

Given String: "In a given health plan your Plan Name: Medical and Plan Type: PPO
whose effective date: 2019-01-01 and coverage value $100 and $200".

1) if I pass "Plan Name:" then my output would be "Medical".
2) if I pass "Plan Type:" then my output would be "PPO".
3) if I pass "effective date:" then my output would be "2019-01-01".
4) if I pass "coverage value" then in this case I need two value.
   Min value "$100" and MAX value "$200".

Similary I need email address from a given sentence.
There could be scenario where I just need to pic a date, email or a numreric value from a given sentence.
In this case I do not have any previous value to match.
 
I need a regular expression logic that covers all above requirnments.


Thanks
Udai Mathur

Answers (1)