pHorseSpec
pHorseSpec

Reputation: 1274

REGEX To Find File

I'm trying to come up with a REGEX statement that searches for

E:\5Year\Logs\text\date\text.NSDQ2.Trans.log.gz 

in

09/29/2006 09:17:41  Adding file E:\6Year\Logs\text\date\text.NSDQ2.Trans.log.gz

so far I have this

[A-Z]:\\dYear\Logs\.+

to find

Upvotes: 1

Views: 31

Answers (1)

Avinash Raj
Avinash Raj

Reputation: 174706

You need to put double backslash to match a single backslash character.

\b[A-Z]:\\\dYear\\Logs\\.+

or

\b[A-Z]:\\\d+Year\\Logs\\.+

Upvotes: 3

Related Questions