in reply to Parsing an Oracle connect string
I get a different result, seems you might want to consider white space, for one thing. That's not allowed, right? Are the pointy brackets legit Oracle chars?while (<DATA>) { chomp; my ($userid, $password, $net_service_name) = m#'?([^@/']+)?(/[^@/']+)?(@[^@/']+)?'?#; print "]]$_\[\[ \tis parsed as \[$userid] \[$password] [$net_service_name]\n" } # while __DATA__ >>SYS/change_on_install@prod1<< <SYS> </change_on_install> <@prod1> >>rman/rman@rcat<< <rman> </rman> <@rcat> >>SYS<< <SYS> <> <> >>/<< <> </> <> >>/fooey<< <> </fooey> <> >>/fooey@foobar<< <> </fooey> <@foobar> >>SYS@foobar<< <SYS> <> <@foobar> >>'simple/fooey@foobar'<< <simple> </fooey> <@foobar>
a
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Parsing an Oracle connect string
by fbicknel (Beadle) on Mar 07, 2011 at 19:44 UTC |