|
-
May 6th, 2005, 06:00 AM
#4
Frenzied Member
Re: SELECT Some words in a field!Please Help
I dont know the code but Im thinkng you could do someting along the lines of-
Store the text to a variable
Set a count = 0
Set 5 variables one for each word
Use a Loop and the Right function to move accross the text by one while and add to the count one each time while the value is not ="". Whilst looping through the characters build up the word in the first variable. On breaking the loop you will have stored in the count the current position. from there you will know the start postition of the second word. You could then peapat this for all five words by adding a second loop around the first which counts to five. An array may make it easier.
Someone else will know a better way but just thought id have a stab at it.
Ps this assumes you use codebehind such as vb.net although I think it can be done this way in T-SQL Also
Last edited by FishGuy; May 6th, 2005 at 06:01 AM.
Reason: added detail
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|