Advertisement

04.09.2008 at 09:01PM PDT, ID: 23310502 | Points: 235
[x]
Attachment Details

I need to edit a large text file removing this pattern i'd like to avoid manual editing

Asked by tyweed420 in Regular Expressions, Miscellaneous Software, Office & Productivity Software

Tags: regular expressions

So, I have a large text file with a bunch of info seperated by "|" . Within each line there are two categories i'd like to remove. The file is very long and i'd like to try to use a regular expression to replace with a space or delete if possible leaving the rest of the contents intact. Here is an example:

path to image | title of movie | genre | format | movie path

i'd like it to be

path to image | title of movie #Release Date:#Genre:#Plot Outline:#Runtime:#Format:  | movie path

so you would be replacing all of  " title| genre | format | " on each line with

title of movie #Release Date:#Genre:#Plot Outline:#Runtime:#Format:


I have attached the file that needs the fixing if someone could do it for me. Or give me instructions how that be great.
I:\Documents and Settings\steve\Desktop\movieGuiFrontEnd\covers\abyss.jpg | Abyss | Adventure | XVID|  "C:\videos\Abyss.SpecialEdition.DVDRip.Xvid.avi "
I:\Documents and Settings\steve\Desktop\movieGuiFrontEnd\covers\adventuresofbaron.jpg | Adventures of Baron Munchausen | Adventure | AVI |  "C:\videos\Adventures of Baron Munchausen, The.avi "
I:\Documents and Settings\steve\Desktop\movieGuiFrontEnd\covers\avp.jpg | Alien vs. Predator | Action | MPEG |  "C:\videos\predator\PredatorvsAlien.avi "
I:\Documents and Settings\steve\Desktop\movieGuiFrontEnd\covers\amadeus.jpg | Amadeus | Drama | XVID |  "C:\videos\Amadeus.DVDRip.XviD.AC3.5.1-GKARlos\Amadeus.DVDRip.XviD.AC3.5.1-GKARlos\Amadeus.DVDRip.XviD.AC3.5.1-GKARlos.avi "
I:\Documents and Settings\steve\Desktop\movieGuiFrontEnd\covers\bf.jpg | Back To The Future | Adventure | DIVX |  "C:\videos\back to the future\Back.To.The.Future.1.1985.DVDivX-SATELLiTE\sat-bttf-cd1.avi" "C:\videos\back to the future\Back.To.The.Future.1.1985.DVDivX-SATELLiTE\sat-bttf-cd2.avi"
I:\Documents and Settings\steve\Desktop\movieGuiFrontEnd\covers\bf2.jpg | Back To The Future 2 | Adventure | DIVX |  "C:\videos\back to the future\Back.To.The.Future.2.1989.iNT.DVDRiP.XViD-ReVOLT\revolt-bttf2a.avi" "C:\videos\back to the future\Back.To.The.Future.2.1989.iNT.DVDRiP.XViD-ReVOLT\revolt-bttf2b.avi"
I:\Documents and Settings\steve\Desktop\movieGuiFrontEnd\covers\bf3.jpg | Back To The Future 3 | Adventure | DIVX |  "C:\videos\back to the future\Back.To.The.Future.3.1990.iNT.DVDRiP.XViD-ReVOLT\revolt-bttf3a.avi" "C:\videos\back to the future\Back.To.The.Future.3.1990.iNT.DVDRiP.XViD-ReVOLT\revolt-bttf3b.avi"
I:\Documents and Settings\steve\Desktop\movieGuiFrontEnd\covers\batman.jpg | Batman | Action | DIVX |  "C:\videos\batman\Batman.1989.DVDRip.DivX-enDi.avi "
I:\Documents and Settings\steve\Desktop\movieGuiFrontEnd\covers\batmanbegins.jpg | Batman Begins | Action | XVID |  "C:\videos\Batman Begins (2005) [ENG] [DVDrip]\Batman Begins (2005) [ENG] [DVDrip] CD1.avi" "C:\videos\Batman Begins (2005) [ENG] [DVDrip]\Batman Begins (2005) [ENG] [DVDrip] CD2.avi"
Start Free Trial
Attachments:
 
file to be fixed
 
[+][-]04.09.2008 at 10:02PM PDT, ID: 21321829

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04.09.2008 at 10:16PM PDT, ID: 21321877

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04.10.2008 at 02:04AM PDT, ID: 21322882

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04.10.2008 at 02:10AM PDT, ID: 21322898

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04.10.2008 at 10:56AM PDT, ID: 21327514

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]04.10.2008 at 02:27PM PDT, ID: 21329538

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04.17.2008 at 11:37PM PDT, ID: 21383659

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04.21.2008 at 10:20AM PDT, ID: 21403988

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628