I have searched the web, and this site but have had no luck in finding a tutorial or set of examples for what I'm needing to do.
I have input that comes in as just a stream of data and it has numerous snippets of information I need to capture.
I need to go through the text and find key words and capture them.....Once the key word is found I have to capture data preceeding and following the key word.
i.e. the incoming stream of data is:
boxer fawn dog 12 34 lab black dog 3 50 yorkshire tan dog 7 35
Dog is the key word, the two words preceeding dog are the breed and colour, and the two numbers following dog are the age of the dog and the age of the owner. Dog is the only consistent word I can try to capture. The actual stream is quite large as well.
I want to put them is a list: boxer brown dog 12 34, lab black dog 3 50, yorkshire tan dog 7 35
and then I can (hopefully) manipulate the data, but so far, I haven't even figured out how to capture the individual snippets of information.
Thanks!
Stephanie
I have input that comes in as just a stream of data and it has numerous snippets of information I need to capture.
I need to go through the text and find key words and capture them.....Once the key word is found I have to capture data preceeding and following the key word.
i.e. the incoming stream of data is:
boxer fawn dog 12 34 lab black dog 3 50 yorkshire tan dog 7 35
Dog is the key word, the two words preceeding dog are the breed and colour, and the two numbers following dog are the age of the dog and the age of the owner. Dog is the only consistent word I can try to capture. The actual stream is quite large as well.
I want to put them is a list: boxer brown dog 12 34, lab black dog 3 50, yorkshire tan dog 7 35
and then I can (hopefully) manipulate the data, but so far, I haven't even figured out how to capture the individual snippets of information.
Thanks!
Stephanie