Does that date stamp exist in another string or on it's own?

\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}

Should do it but it won't stop invalid dates like

2008-99-99T99:99:99

Adrian

Building a DB of errors at http://cferror.org/

-----Original Message-----
From: AJ Mercer [mailto:[EMAIL PROTECTED]
Sent: 07 October 2008 09:32
To: cf-talk
Subject: ReFind - finding too much :-(


I have a generic function that processes all sorts of data
One in particular I want to identify and do a search and replace on
    sample data: 2008-10-07T16:21:17
I want to swap the T for a space
But I only want to do it if the data is in this format

I came up with this, but it is returning true for pretty well everything :-(
    <cfif ReFind("[(0-9)4\-(0-9)2\-(0-9)2T(0-9)2:(0-9)2:(0-9)2]",
local.fieldValue)>

Can some one please point out what I am doing wrong here?

--
AJ Mercer
Web Log: http://webonix.net


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:313511
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

Reply via email to