[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[no subject]



> On Thu, Aug 18, 2005 at 02:40:35PM -0600, Joe Knapka wrote:
> > Jason Day <jasonday at worldnet.att.net> writes:
> > > Try "[^ ]?XMI001".  That should match the string "XMI001" optionally
> > > preceded by any character that is not a space.  If you want to match 0
> > > or more non-spaces, use "[^ ]*XMI001".
> > 
> > But the string "   XMI001" *is* an instance of "XMI001" preceded by
> > zero non-space characters (and those zero non-spaces are preceded
> > by some spaces), so would match both of your expressions.
> 
> Damn, you're absolutely right.
> 
> What about "([^ ]|^)XMI001"?  That should match against a non-space OR
> the beginning of line (or string) followed by the XMI001.  I know Chris
> said the regex engine is not seeing the lines, but I'm curious if this
> would work.

Yes, it should, I think. I'd like to see an actual sample of the data
Chris is trying to process.

-- Joe



</pre>
<!--X-Body-of-Message-End-->
<!--X-MsgBody-End-->
<!--X-Follow-Ups-->
<hr>
<ul><li><strong>Follow-Ups</strong>:
<ul>
<li><strong><a name="00308" href="msg00308.html">[ale] Yet another regex question</a></strong>
<ul><li><em>From:</em> cfowler at outpostsentinel.com (Christopher Fowler)</li></ul></li>
</ul></li></ul>
<!--X-Follow-Ups-End-->
<!--X-References-->
<ul><li><strong>References</strong>:
<ul>
<li><strong><a name="00130" href="msg00130.html">[ale] Yet another regex question</a></strong>
<ul><li><em>From:</em> cfowler at outpostsentinel.com (Christopher Fowler)</li></ul></li>
<li><strong><a name="00131" href="msg00131.html">[ale] Yet another regex question</a></strong>
<ul><li><em>From:</em> jimpop at yahoo.com (Jim Popovitch)</li></ul></li>
<li><strong><a name="00132" href="msg00132.html">[ale] Yet another regex question</a></strong>
<ul><li><em>From:</em> cfowler at outpostsentinel.com (Christopher Fowler)</li></ul></li>
<li><strong><a name="00133" href="msg00133.html">[ale] Yet another regex question</a></strong>
<ul><li><em>From:</em> cfowler at outpostsentinel.com (Christopher Fowler)</li></ul></li>
<li><strong><a name="00136" href="msg00136.html">[ale] Yet another regex question</a></strong>
<ul><li><em>From:</em> jimpop at yahoo.com (Jim Popovitch)</li></ul></li>
<li><strong><a name="00138" href="msg00138.html">[ale] Yet another regex question</a></strong>
<ul><li><em>From:</em> cfowler at outpostsentinel.com (Christopher Fowler)</li></ul></li>
<li><strong><a name="00206" href="msg00206.html">[ale] Yet another regex question</a></strong>
<ul><li><em>From:</em> jasonday at worldnet.att.net (Jason Day)</li></ul></li>
<li><strong><a name="00279" href="msg00279.html">[ale] Yet another regex question</a></strong>
<ul><li><em>From:</em> jknapka at kneuro.net (Joe Knapka)</li></ul></li>
<li><strong><a name="00290" href="msg00290.html">[ale] Yet another regex question</a></strong>
<ul><li><em>From:</em> jasonday at worldnet.att.net (Jason Day)</li></ul></li>
</ul></li></ul>
<!--X-References-End-->
<!--X-BotPNI-->
<ul>
<li>Prev by Date:
<strong><a href="msg00306.html">[ale] Redefine CTRL+ALT+(Numeric +)</a></strong>
</li>
<li>Next by Date:
<strong><a href="msg00304.html">[ale] Gone (totally) OT: Cobb Laptop Deal</a></strong>
</li>
<li>Previous by thread:
<strong><a href="msg00290.html">[ale] Yet another regex question</a></strong>
</li>
<li>Next by thread:
<strong><a href="msg00308.html">[ale] Yet another regex question</a></strong>
</li>
<li>Index(es):
<ul>
<li><a href="maillist.html#00303"><strong>Date</strong></a></li>
<li><a href="threads.html#00303"><strong>Thread</strong></a></li>
</ul>
</li>
</ul>

<!--X-BotPNI-End-->
<!--X-User-Footer-->
<!--X-User-Footer-End-->
</body>
</html>