At 23:51 -0400 on 05/11/2004, Michael Stassen wrote about Re: check
for certain characters:
Then you could add NOT to Paul's query:
SELECT * FROM your table WHERE sequence NOT REGEXP '^[atcg]+$';
or, equivalently,
SELECT * FROM your table WHERE sequence REGEXP '[^at
Then you could add NOT to Paul's query:
SELECT * FROM your table WHERE sequence NOT REGEXP '^[atcg]+$';
or, equivalently,
SELECT * FROM your table WHERE sequence REGEXP '[^atcg]';
I suspect the latter may be faster, but you'd have to try them to be sure.
Note that pattern matching in mysql
the output of the query should be: all the records that contain even one
letter other than a,t,c or g.
Liz
Quoting Paul DuBois <[EMAIL PROTECTED]>:
> At 21:41 -0400 5/11/04, [EMAIL PROTECTED] wrote:
> >hi,
> > I have a field which is a genome sequence and I need to check if
> each of
> >th
At 21:41 -0400 5/11/04, [EMAIL PROTECTED] wrote:
hi,
I have a field which is a genome sequence and I need to check if each of
the entries made for the sequence field contains only a,t,c or g in the string
and no other characters.
how will i give the query???
It depends. You can find matching v
slow.
--
DVP
> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, May 11, 2004 5:42 PM
> To: [EMAIL PROTECTED]
> Subject: check for certain characters
>
> hi,
> I have a field which is a genome sequence and I need to check if
hi,
I have a field which is a genome sequence and I need to check if each of
the entries made for the sequence field contains only a,t,c or g in the string
and no other characters.
how will i give the query???
thanks,
liz
--
MySQL General Mailing List
For list archives: http://lists.mysql.