Anyone have ideas on this?

<!----------------//------
andy matthews
web developer
ICGLink, Inc.
[EMAIL PROTECTED]
615.370.1530 x737
--------------//--------->

-----Original Message-----
From: Andy Matthews [mailto:[EMAIL PROTECTED]
Sent: Monday, January 09, 2006 9:35 AM
To: CF-Talk
Subject: SOT: SQL query to get first sentence (using mySQL)


I've got a text field from which I'd like to extract the first sentence for
each record. Here's the query I've got so far.

SELECT SUBSTRING_INDEX(j.job_desc,'.',1) AS job_desc
FROM jobs

The problem is that in some of the records, the first sentence is terminated
by a question mark (or exclamation point) rather than a period and I need to
get those sentences as well. I'm trying to find out how I can say "the first
sentence" instead of "the first sentence ending in a period".

Does anyone have any ideas?

<!----------------//------
andy matthews
web developer
ICGLink, Inc.
[EMAIL PROTECTED]
615.370.1530 x737
--------------//--------->




~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:229025
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to