1

I am using the information I found on this post

Perl: add character to begin of a line

to create this perl command (I need to add a |1 to the end of each string)

perl -p -e 's/$/|1/' C:\Users\Leslie\TABLE0212201314402-out.csv > C:\Users\Leslie\new.csv

and I get the error:

'1' is not recognized as an internal or external command, operable program or batch file

Do I need to do something to my |1 so that it works? Thanks, Leslie

1 Answer 1

3

Try this instead :

perl -p -e "s/$/|1/" C:\Users\Leslie\TABLE0212201314402-out.csv > C:\Users\Leslie\new.csv

Note the use of double quotes instead of single quotes for the Windows command shell.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.