in reply to Re^3: Cutting last word from a output line
in thread Cutting last word from a output line

Thanks Karl, I just gave an example how i was achieving in unix shell. Ok i will try to re-phrase the question. I am expecting like below. Assume below is an system command: "snmpwalk.ovpl -c $string $IP sysName" here windows system command "snmpwalk.ovpl -c $string $IP sysName" will give me output like below. sysName.0 : OCTET STRING- (ascii): USWLS-P-TR03-C4510RE-1.adagnet.net So as said earlier i am expecting something like below.: my $variable = `system (sysName.0 : OCTET STRING- (ascii): USWLS-P-TR03-C4510RE-1.adagnet.net) | cut last word` expected $variable=USWLS-P-TR03-C4510RE-1.adagnet.net
  • Comment on Re^4: Cutting last word from a output line

Replies are listed 'Best First'.
Re^5: Cutting last word from a output line
by karlgoethebier (Abbot) on Feb 28, 2015 at 17:26 UTC

    Thank you very much. So the solution given above by kroach works for you.

    Regards, Karl

    «The Crux of the Biscuit is the Apostrophe»