Regular expression to extract information
anjie451
-
blux Posted messages 5003 Registration date Status Modérateur Last intervention -
blux Posted messages 5003 Registration date Status Modérateur Last intervention -
Hello,
I'm looking for a formula to extract all spaces (blanks) from a text, and for that, I need to use regular expressions like [a-z A-Z]* [F f]red[a-z] which means any string containing the word Fred
Can someone help me???? I'm lost!
Thank youuuu
I'm looking for a formula to extract all spaces (blanks) from a text, and for that, I need to use regular expressions like [a-z A-Z]* [F f]red[a-z] which means any string containing the word Fred
Can someone help me???? I'm lost!
Thank youuuu
Configuration: Windows XP Firefox 3.5.7
4 réponses
Hi,
what do you mean by 'extracting'?
--
A+ Blux
what do you mean by 'extracting'?
--
A+ Blux
"The idiots, they dare to do anything. That's how we recognize them."
Extracting means spotting in a text all occurrences of my choice. In this case, therefore, the white spaces.
There is no specific language; we call this information extraction using regular expressions or patterns.
There is no specific language; we call this information extraction using regular expressions or patterns.
I know how regular expressions work, but I still don't understand the meaning of your question: do you want to count them?
A regular expression can be used to delete characters, replace them, find them, or even assign them to variables for use in the same expression...
--
A+ Blux
A regular expression can be used to delete characters, replace them, find them, or even assign them to variables for use in the same expression...
--
A+ Blux
"Fools dare anything. It's even how we recognize them."
[^ ]+
This is something that starts with several spaces...
In textpad, you search, and in the dialog box, you check regular expression and you can put either a space or a space in brackets (for readability).
Note that the [] are there to indicate a choice range.
--
See you Blux
This is something that starts with several spaces...
In textpad, you search, and in the dialog box, you check regular expression and you can put either a space or a space in brackets (for readability).
Note that the [] are there to indicate a choice range.
--
See you Blux
"The idiots, they dare everything. It's even how we recognize them"