Hello SAS experts,
I have a question regarding identify the multiple positions of the same word in a string. For example, I have a string containing all the medical chart notes and I want to identify the positions of the word insulin used in the note every time.
The note is like:
"Insulin glargine increased to 85 units twice a day. This may not be the right level to control your blood sugar, and so you will be called Saturday 9/7/13 to see how your blood sugar levels are doing. You will likely only need to continue with this higher dose of insulin while you are taking steroids.
INSULIN GLARGINE INJ
Directions: inject 85units under the skin twice a day do not mix with other
insulins, discard open vials after 28 days
INSULIN,ASPART 100UN/ML NOVO FLEXPEN 3ML
Directions: Inject sliding scale under the skin before meals and at bedtime (for diabetes) , use this scale to determine insulin dose.for blood sugar "
I have boldened, reddened and underlined the keyword insulin, which also have lower/upper case change. Is there a way to output the position for each insulin used, such as insulin_pos1=50, insulin_pos2=100, insulin_pos3=150, etc?
Thank you all.