I have a string -
"126_VAMSI, SWAP L. NA_8092069876"
i need to get "VAMSI, SWAP L. NA" as an output i.e. the words between the underscore, then what should be my approach.
I have a string -
"126_VAMSI, SWAP L. NA_8092069876"
i need to get "VAMSI, SWAP L. NA" as an output i.e. the words between the underscore, then what should be my approach.
If your question is complete and string only has two underscores and you want the middle text between underscores. Then this is your answer.
str.split("_")[1];
If your questioned string is variant pls elaborate