Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

(MeowChow) Re: Delete unmatched quotes from a delimited file?

by MeowChow (Vicar)
on Jul 24, 2001 at 21:58 UTC ( #99430=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    s/((?:^|\|)(?:[^"|]*"[^"|]*")*[^"|]*)"([^"|]*)(?=$|\|)/$1$2/g;
    
  2. or download this
    my $T = qr/[^"|]*/;
    s/((?:^|\|)(?:$T"$T")*$T)"($T)(?=$|\|)/$1$2/go;
    
  3. or download this
    join '|', map { s/"([^"]*)$/$1/ if y/"// & 1; $_ } split /\|/;
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://99430]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (4)
As of 2022-01-23 03:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    In 2022, my preferred method to securely store passwords is:












    Results (63 votes). Check out past polls.

    Notices?