List:General Discussion« Previous MessageNext Message »
From:Keith Ivey Date:March 24 2005 8:00pm
Subject:Re: a very tricky string extraction
View as plain text  
Ed Reed wrote:

> 01/01/05 SG Reviewed this
> 12/15/03 DSD Reviewed that 
> 10/24/02 EWW Worked on that and tested this then stop to do something
> else
> 05/02/01 AW Did something
> 08/31/98 DSD Tested this
> 07/22/97 EWW Worked on that and did something 
>  
> I need a Select statement that returns the Date for the first occurance
> of the 'Tested this' substring

That's the sort of thing you're going to be better off doing in 
Perl or PHP or whatever applicationn language you're using 
rather than trying to handle in your MySQL query.  And of course 
if it's something you're doing regularly, rather than a one-time 
conversion, you should put that data into a proper table, with 
date, initials, and description as columns.

If you're determined to do it, you'll need a bunch of 
applications of LOCATION() and SUBSTRING(), and probably IF().

-- 
Keith Ivey <keith@stripped>
Smokefree DC
http://www.smokefreedc.org
Washington, DC
Thread
a very tricky string extractionEd Reed24 Mar
  • Re: a very tricky string extractionDan Nelson24 Mar
    • Re: a very tricky string extractionKeith Ivey24 Mar
  • Re: a very tricky string extractionKeith Ivey24 Mar
  • Re: a very tricky string extractionJoerg Bruehe24 Mar
  • Re: a very tricky string extractionSGreen24 Mar
RE: a very tricky string extractionJay Blanchard24 Mar
RE: a very tricky string extractionJay Blanchard24 Mar
Re: a very tricky string extractionEd Reed24 Mar
  • Re: a very tricky string extractionSGreen24 Mar
Re: a very tricky string extractionEd Reed24 Mar
  • Re: a very tricky string extractionEamon Daly24 Mar
    • Re: a very tricky string extractionKeith Ivey24 Mar
  • Re: a very tricky string extractionEamon Daly25 Mar
Re: a very tricky string extractionEd Reed24 Mar